diff options
author | Muxi Yan <mxyan@google.com> | 2017-04-25 16:02:09 -0700 |
---|---|---|
committer | Muxi Yan <mxyan@google.com> | 2017-04-25 17:04:29 -0700 |
commit | b53fd4df37617364e6de2d9f880c03f3a9907450 (patch) | |
tree | 090bc3b59310f86ec5bf08c87d06c9fa71a9ed59 | |
parent | c090c619c117912b8c9e88a3c4bc8f778a94d582 (diff) |
Add cronet_compression workaround filter
-rw-r--r-- | CMakeLists.txt | 2 | ||||
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | binding.gyp | 1 | ||||
-rw-r--r-- | build.yaml | 10 | ||||
-rw-r--r-- | config.m4 | 2 | ||||
-rw-r--r-- | gRPC-Core.podspec | 5 | ||||
-rwxr-xr-x | grpc.gemspec | 2 | ||||
-rw-r--r-- | package.xml | 2 | ||||
-rw-r--r-- | src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c | 149 | ||||
-rw-r--r-- | src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h | 39 | ||||
-rw-r--r-- | src/core/plugin_registry/grpc_plugin_registry.c | 4 | ||||
-rw-r--r-- | src/core/plugin_registry/grpc_unsecure_plugin_registry.c | 4 | ||||
-rw-r--r-- | src/python/grpcio/grpc_core_dependencies.py | 1 | ||||
-rw-r--r-- | tools/doxygen/Doxyfile.core.internal | 2 | ||||
-rw-r--r-- | tools/run_tests/generated/sources_and_headers.json | 24 | ||||
-rw-r--r-- | vsprojects/vcxproj/grpc/grpc.vcxproj | 3 | ||||
-rw-r--r-- | vsprojects/vcxproj/grpc/grpc.vcxproj.filters | 9 | ||||
-rw-r--r-- | vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj | 3 | ||||
-rw-r--r-- | vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters | 9 |
19 files changed, 270 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 1d7662031d..106985a290 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1149,6 +1149,7 @@ add_library(grpc src/core/ext/census/tracing.c src/core/ext/filters/max_age/max_age_filter.c src/core/ext/filters/message_size/message_size_filter.c + src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c src/core/plugin_registry/grpc_plugin_registry.c ) @@ -2011,6 +2012,7 @@ add_library(grpc_unsecure src/core/ext/census/tracing.c src/core/ext/filters/max_age/max_age_filter.c src/core/ext/filters/message_size/message_size_filter.c + src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c src/core/plugin_registry/grpc_unsecure_plugin_registry.c ) @@ -3123,6 +3123,7 @@ LIBGRPC_SRC = \ src/core/ext/census/tracing.c \ src/core/ext/filters/max_age/max_age_filter.c \ src/core/ext/filters/message_size/message_size_filter.c \ + src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c \ src/core/plugin_registry/grpc_plugin_registry.c \ PUBLIC_HEADERS_C += \ @@ -3954,6 +3955,7 @@ LIBGRPC_UNSECURE_SRC = \ src/core/ext/census/tracing.c \ src/core/ext/filters/max_age/max_age_filter.c \ src/core/ext/filters/message_size/message_size_filter.c \ + src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c \ src/core/plugin_registry/grpc_unsecure_plugin_registry.c \ PUBLIC_HEADERS_C += \ diff --git a/binding.gyp b/binding.gyp index a08bf78263..7487ca7f81 100644 --- a/binding.gyp +++ b/binding.gyp @@ -886,6 +886,7 @@ 'src/core/ext/census/tracing.c', 'src/core/ext/filters/max_age/max_age_filter.c', 'src/core/ext/filters/message_size/message_size_filter.c', + 'src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c', 'src/core/plugin_registry/grpc_plugin_registry.c', ], "conditions": [ diff --git a/build.yaml b/build.yaml index 52ddc3287f..40333e40ff 100644 --- a/build.yaml +++ b/build.yaml @@ -793,6 +793,14 @@ filegroups: - grpc_base - grpc_transport_chttp2 - grpc_http_filters +- name: grpc_workaround_cronet_compression_filter + headers: + - src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h + src: + - src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c + plugin: grpc_workaround_cronet_compression_filter + uses: + - grpc_base - name: nanopb headers: - third_party/nanopb/pb.h @@ -1025,6 +1033,7 @@ libs: - grpc_max_age_filter - grpc_message_size_filter - grpc_deadline_filter + - grpc_workaround_cronet_compression_filter generate_plugin_registry: true secure: true vs_packages: @@ -1124,6 +1133,7 @@ libs: - grpc_max_age_filter - grpc_message_size_filter - grpc_deadline_filter + - grpc_workaround_cronet_compression_filter generate_plugin_registry: true secure: false vs_project_guid: '{46CEDFFF-9692-456A-AA24-38B5D6BCF4C5}' @@ -322,6 +322,7 @@ if test "$PHP_GRPC" != "no"; then src/core/ext/census/tracing.c \ src/core/ext/filters/max_age/max_age_filter.c \ src/core/ext/filters/message_size/message_size_filter.c \ + src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c \ src/core/plugin_registry/grpc_plugin_registry.c \ src/boringssl/err_data.c \ third_party/boringssl/crypto/aes/aes.c \ @@ -702,6 +703,7 @@ if test "$PHP_GRPC" != "no"; then PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/filters/load_reporting) PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/filters/max_age) PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/filters/message_size) + PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/filters/workarounds) PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/transport/chttp2/alpn) PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/transport/chttp2/client) PHP_ADD_BUILD_DIR($ext_builddir/src/core/ext/transport/chttp2/client/insecure) diff --git a/gRPC-Core.podspec b/gRPC-Core.podspec index 4bd9cd9363..854e9b9cd0 100644 --- a/gRPC-Core.podspec +++ b/gRPC-Core.podspec @@ -459,6 +459,7 @@ Pod::Spec.new do |s| 'src/core/ext/census/tracing.h', 'src/core/ext/filters/max_age/max_age_filter.h', 'src/core/ext/filters/message_size/message_size_filter.h', + 'src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h', 'src/core/lib/surface/init.c', 'src/core/lib/channel/channel_args.c', 'src/core/lib/channel/channel_stack.c', @@ -694,6 +695,7 @@ Pod::Spec.new do |s| 'src/core/ext/census/tracing.c', 'src/core/ext/filters/max_age/max_age_filter.c', 'src/core/ext/filters/message_size/message_size_filter.c', + 'src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c', 'src/core/plugin_registry/grpc_plugin_registry.c' ss.private_header_files = 'src/core/lib/profiling/timers.h', @@ -913,7 +915,8 @@ Pod::Spec.new do |s| 'src/core/ext/census/trace_string.h', 'src/core/ext/census/tracing.h', 'src/core/ext/filters/max_age/max_age_filter.h', - 'src/core/ext/filters/message_size/message_size_filter.h' + 'src/core/ext/filters/message_size/message_size_filter.h', + 'src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h' end s.subspec 'Cronet-Interface' do |ss| diff --git a/grpc.gemspec b/grpc.gemspec index e53bd29cd4..4d1c22cd5c 100755 --- a/grpc.gemspec +++ b/grpc.gemspec @@ -375,6 +375,7 @@ Gem::Specification.new do |s| s.files += %w( src/core/ext/census/tracing.h ) s.files += %w( src/core/ext/filters/max_age/max_age_filter.h ) s.files += %w( src/core/ext/filters/message_size/message_size_filter.h ) + s.files += %w( src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h ) s.files += %w( src/core/lib/surface/init.c ) s.files += %w( src/core/lib/channel/channel_args.c ) s.files += %w( src/core/lib/channel/channel_stack.c ) @@ -610,6 +611,7 @@ Gem::Specification.new do |s| s.files += %w( src/core/ext/census/tracing.c ) s.files += %w( src/core/ext/filters/max_age/max_age_filter.c ) s.files += %w( src/core/ext/filters/message_size/message_size_filter.c ) + s.files += %w( src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c ) s.files += %w( src/core/plugin_registry/grpc_plugin_registry.c ) s.files += %w( third_party/boringssl/crypto/aes/internal.h ) s.files += %w( third_party/boringssl/crypto/asn1/asn1_locl.h ) diff --git a/package.xml b/package.xml index 8e6b30e07e..108b144e38 100644 --- a/package.xml +++ b/package.xml @@ -384,6 +384,7 @@ <file baseinstalldir="/" name="src/core/ext/census/tracing.h" role="src" /> <file baseinstalldir="/" name="src/core/ext/filters/max_age/max_age_filter.h" role="src" /> <file baseinstalldir="/" name="src/core/ext/filters/message_size/message_size_filter.h" role="src" /> + <file baseinstalldir="/" name="src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h" role="src" /> <file baseinstalldir="/" name="src/core/lib/surface/init.c" role="src" /> <file baseinstalldir="/" name="src/core/lib/channel/channel_args.c" role="src" /> <file baseinstalldir="/" name="src/core/lib/channel/channel_stack.c" role="src" /> @@ -619,6 +620,7 @@ <file baseinstalldir="/" name="src/core/ext/census/tracing.c" role="src" /> <file baseinstalldir="/" name="src/core/ext/filters/max_age/max_age_filter.c" role="src" /> <file baseinstalldir="/" name="src/core/ext/filters/message_size/message_size_filter.c" role="src" /> + <file baseinstalldir="/" name="src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c" role="src" /> <file baseinstalldir="/" name="src/core/plugin_registry/grpc_plugin_registry.c" role="src" /> <file baseinstalldir="/" name="third_party/boringssl/crypto/aes/internal.h" role="src" /> <file baseinstalldir="/" name="third_party/boringssl/crypto/asn1/asn1_locl.h" role="src" /> diff --git a/src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c b/src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c new file mode 100644 index 0000000000..f78cfa2f55 --- /dev/null +++ b/src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c @@ -0,0 +1,149 @@ +// +// Copyright 2017, Google Inc. +// 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 Inc. 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 THE COPYRIGHT +// OWNER OR CONTRIBUTORS 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 "src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h" + +#include <string.h> + +#include "src/core/lib/surface/channel_init.h" +#include "src/core/lib/channel/channel_stack_builder.h" +/* +#include <grpc/impl/codegen/grpc_types.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/support/string.h" +#include "src/core/lib/transport/service_config.h" +*/ + +#define GRPC_WORKAROUND_PRIORITY_HIGH 9999 + +typedef struct call_data { + // Receive closures are chained: we inject this closure as the + // recv_initial_metadata_ready up-call on transport_stream_op, and remember to + // call our next_recv_initial_metadata_ready member after handling it. + grpc_closure recv_initial_metadata_ready; + // Used by recv_initial_metadata_ready. + grpc_metadata_batch *recv_initial_metadata; + // Original recv_initial_metadata_ready callback, invoked after our own. + grpc_closure* next_recv_initial_metadata_ready; +} call_data; + +typedef struct channel_data { +} channel_data; + +// Callback invoked when we receive an initial metadata. +static void recv_initial_metadata_ready(grpc_exec_ctx* exec_ctx, void* user_data, + grpc_error* error) { + grpc_call_element* elem = user_data; + call_data* calld = elem->call_data; + + + + // Invoke the next callback. + grpc_closure_run(exec_ctx, calld->next_recv_initial_metadata_ready, GRPC_ERROR_REF(error)); +} + +// Start transport stream op. +static void start_transport_stream_op_batch( + grpc_exec_ctx* exec_ctx, grpc_call_element* elem, + grpc_transport_stream_op_batch* op) { + call_data* calld = elem->call_data; + + // Inject callback for receiving initial metadata + if (op->recv_initial_metadata) { + calld->next_recv_initial_metadata_ready = + op->payload->recv_initial_metadata.recv_initial_metadata_ready; + op->payload->recv_initial_metadata.recv_initial_metadata_ready = &calld->recv_initial_metadata_ready; + calld->recv_initial_metadata = op->payload->recv_initial_metadata.recv_initial_metadata; + } + + // Chain to the next filter. + grpc_call_next_op(exec_ctx, elem, op); +} + +// Constructor for call_data. +static grpc_error* init_call_elem(grpc_exec_ctx* exec_ctx, + grpc_call_element* elem, + const grpc_call_element_args* args) { + call_data* calld = elem->call_data; + calld->next_recv_initial_metadata_ready = NULL; + grpc_closure_init(&calld->recv_initial_metadata_ready, recv_initial_metadata_ready, elem, + grpc_schedule_on_exec_ctx); + return GRPC_ERROR_NONE; +} + +// Destructor for call_data. +static void destroy_call_elem(grpc_exec_ctx* exec_ctx, grpc_call_element* elem, + const grpc_call_final_info* final_info, + grpc_closure* ignored) {} + +// Constructor for channel_data. +static grpc_error* init_channel_elem(grpc_exec_ctx* exec_ctx, + grpc_channel_element* elem, + grpc_channel_element_args* args) { + return GRPC_ERROR_NONE; +} + +// Destructor for channel_data. +static void destroy_channel_elem(grpc_exec_ctx* exec_ctx, + grpc_channel_element* elem) {} + +const grpc_channel_filter grpc_workaround_cronet_compression_filter = { + start_transport_stream_op_batch, + grpc_channel_next_op, + sizeof(call_data), + init_call_elem, + grpc_call_stack_ignore_set_pollset_or_pollset_set, + destroy_call_elem, + sizeof(channel_data), + init_channel_elem, + destroy_channel_elem, + grpc_call_next_get_peer, + grpc_channel_next_get_info, + "workaround_cronet_compression"}; + +static bool register_workaround_cronet_compression(grpc_exec_ctx* exec_ctx, + grpc_channel_stack_builder* builder, + void* arg) { + return grpc_channel_stack_builder_prepend_filter( + builder, &grpc_workaround_cronet_compression_filter, NULL, NULL); +} + +void grpc_workaround_cronet_compression_filter_init(void) { + grpc_channel_init_register_stage(GRPC_SERVER_CHANNEL, + GRPC_WORKAROUND_PRIORITY_HIGH, + register_workaround_cronet_compression, NULL); +} + +void grpc_workaround_cronet_compression_filter_shutdown(void) {} diff --git a/src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h b/src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h new file mode 100644 index 0000000000..289223477f --- /dev/null +++ b/src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h @@ -0,0 +1,39 @@ +// +// Copyright 2017, Google Inc. +// 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 Inc. 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 THE COPYRIGHT +// OWNER OR CONTRIBUTORS 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 GRPC_CORE_EXT_FILTERS_WORKAROUNDS_WORKAROUND_CRONET_COMPRESSION +#define GRPC_CORE_EXT_FILTERS_WORKAROUNDS_WORKAROUND_CRONET_COMPRESSION + +#include "src/core/lib/channel/channel_stack.h" + +extern const grpc_channel_filter grpc_workaround_cronet_compression_filter; + +#endif /* GRPC_CORE_EXT_FILTERS_WORKAROUNDS_WORKAROUND_CRONET_COMPRESSION */ diff --git a/src/core/plugin_registry/grpc_plugin_registry.c b/src/core/plugin_registry/grpc_plugin_registry.c index 25bda7a262..510cf5d5a0 100644 --- a/src/core/plugin_registry/grpc_plugin_registry.c +++ b/src/core/plugin_registry/grpc_plugin_registry.c @@ -61,6 +61,8 @@ extern void grpc_max_age_filter_init(void); extern void grpc_max_age_filter_shutdown(void); extern void grpc_message_size_filter_init(void); extern void grpc_message_size_filter_shutdown(void); +extern void grpc_workaround_cronet_compression_filter_init(void); +extern void grpc_workaround_cronet_compression_filter_shutdown(void); void grpc_register_built_in_plugins(void) { grpc_register_plugin(grpc_http_filters_init, @@ -91,4 +93,6 @@ void grpc_register_built_in_plugins(void) { grpc_max_age_filter_shutdown); grpc_register_plugin(grpc_message_size_filter_init, grpc_message_size_filter_shutdown); + grpc_register_plugin(grpc_workaround_cronet_compression_filter_init, + grpc_workaround_cronet_compression_filter_shutdown); } diff --git a/src/core/plugin_registry/grpc_unsecure_plugin_registry.c b/src/core/plugin_registry/grpc_unsecure_plugin_registry.c index 05d4771bce..e5eb68f934 100644 --- a/src/core/plugin_registry/grpc_unsecure_plugin_registry.c +++ b/src/core/plugin_registry/grpc_unsecure_plugin_registry.c @@ -61,6 +61,8 @@ extern void grpc_max_age_filter_init(void); extern void grpc_max_age_filter_shutdown(void); extern void grpc_message_size_filter_init(void); extern void grpc_message_size_filter_shutdown(void); +extern void grpc_workaround_cronet_compression_filter_init(void); +extern void grpc_workaround_cronet_compression_filter_shutdown(void); void grpc_register_built_in_plugins(void) { grpc_register_plugin(grpc_http_filters_init, @@ -91,4 +93,6 @@ void grpc_register_built_in_plugins(void) { grpc_max_age_filter_shutdown); grpc_register_plugin(grpc_message_size_filter_init, grpc_message_size_filter_shutdown); + grpc_register_plugin(grpc_workaround_cronet_compression_filter_init, + grpc_workaround_cronet_compression_filter_shutdown); } diff --git a/src/python/grpcio/grpc_core_dependencies.py b/src/python/grpcio/grpc_core_dependencies.py index 16bb32bcc6..3620662276 100644 --- a/src/python/grpcio/grpc_core_dependencies.py +++ b/src/python/grpcio/grpc_core_dependencies.py @@ -311,6 +311,7 @@ CORE_SOURCE_FILES = [ 'src/core/ext/census/tracing.c', 'src/core/ext/filters/max_age/max_age_filter.c', 'src/core/ext/filters/message_size/message_size_filter.c', + 'src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c', 'src/core/plugin_registry/grpc_plugin_registry.c', 'src/boringssl/err_data.c', 'third_party/boringssl/crypto/aes/aes.c', diff --git a/tools/doxygen/Doxyfile.core.internal b/tools/doxygen/Doxyfile.core.internal index 924595eb95..ab23bf316e 100644 --- a/tools/doxygen/Doxyfile.core.internal +++ b/tools/doxygen/Doxyfile.core.internal @@ -971,6 +971,8 @@ src/core/ext/filters/max_age/max_age_filter.c \ src/core/ext/filters/max_age/max_age_filter.h \ src/core/ext/filters/message_size/message_size_filter.c \ src/core/ext/filters/message_size/message_size_filter.h \ +src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c \ +src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h \ src/core/ext/transport/README.md \ src/core/ext/transport/chttp2/README.md \ src/core/ext/transport/chttp2/alpn/alpn.c \ diff --git a/tools/run_tests/generated/sources_and_headers.json b/tools/run_tests/generated/sources_and_headers.json index 1f3bf7837f..b62fa9939d 100644 --- a/tools/run_tests/generated/sources_and_headers.json +++ b/tools/run_tests/generated/sources_and_headers.json @@ -5710,7 +5710,8 @@ "grpc_transport_chttp2_client_insecure", "grpc_transport_chttp2_client_secure", "grpc_transport_chttp2_server_insecure", - "grpc_transport_chttp2_server_secure" + "grpc_transport_chttp2_server_secure", + "grpc_workaround_cronet_compression_filter" ], "headers": [], "is_filegroup": false, @@ -5812,7 +5813,8 @@ "grpc_resolver_dns_native", "grpc_resolver_sockaddr", "grpc_transport_chttp2_client_insecure", - "grpc_transport_chttp2_server_insecure" + "grpc_transport_chttp2_server_insecure", + "grpc_workaround_cronet_compression_filter" ], "headers": [], "is_filegroup": false, @@ -8756,6 +8758,24 @@ "type": "filegroup" }, { + "deps": [ + "gpr", + "grpc_base" + ], + "headers": [ + "src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h" + ], + "is_filegroup": true, + "language": "c", + "name": "grpc_workaround_cronet_compression_filter", + "src": [ + "src/core/ext/filters/workarounds/workaround_cronet_compression_filter.c", + "src/core/ext/filters/workarounds/workaround_cronet_compression_filter.h" + ], + "third_party": false, + "type": "filegroup" + }, + { "deps": [], "headers": [ "third_party/nanopb/pb.h", diff --git a/vsprojects/vcxproj/grpc/grpc.vcxproj b/vsprojects/vcxproj/grpc/grpc.vcxproj index ca70dde793..2a2c795428 100644 --- a/vsprojects/vcxproj/grpc/grpc.vcxproj +++ b/vsprojects/vcxproj/grpc/grpc.vcxproj @@ -504,6 +504,7 @@ <ClInclude Include="$(SolutionDir)\..\src\core\ext\census\tracing.h" /> <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\max_age\max_age_filter.h" /> <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.h" /> + <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.h" /> </ItemGroup> <ItemGroup> <ClCompile Include="$(SolutionDir)\..\src\core\lib\surface\init.c"> @@ -976,6 +977,8 @@ </ClCompile> <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.c"> </ClCompile> + <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.c"> + </ClCompile> <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_plugin_registry.c"> </ClCompile> </ItemGroup> diff --git a/vsprojects/vcxproj/grpc/grpc.vcxproj.filters b/vsprojects/vcxproj/grpc/grpc.vcxproj.filters index acadc0ad88..fa043cfcf5 100644 --- a/vsprojects/vcxproj/grpc/grpc.vcxproj.filters +++ b/vsprojects/vcxproj/grpc/grpc.vcxproj.filters @@ -706,6 +706,9 @@ <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.c"> <Filter>src\core\ext\filters\message_size</Filter> </ClCompile> + <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.c"> + <Filter>src\core\ext\filters\workarounds</Filter> + </ClCompile> <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_plugin_registry.c"> <Filter>src\core\plugin_registry</Filter> </ClCompile> @@ -1418,6 +1421,9 @@ <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.h"> <Filter>src\core\ext\filters\message_size</Filter> </ClInclude> + <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.h"> + <Filter>src\core\ext\filters\workarounds</Filter> + </ClInclude> </ItemGroup> <ItemGroup> @@ -1517,6 +1523,9 @@ <Filter Include="src\core\ext\filters\message_size"> <UniqueIdentifier>{5ca3f38c-539f-3c4f-b68c-38b31ba339ba}</UniqueIdentifier> </Filter> + <Filter Include="src\core\ext\filters\workarounds"> + <UniqueIdentifier>{2ec64619-e2c4-da0f-c10e-e03f5a151300}</UniqueIdentifier> + </Filter> <Filter Include="src\core\ext\transport"> <UniqueIdentifier>{e3abfd0a-064e-0f2f-c8e8-7c5a7e98142a}</UniqueIdentifier> </Filter> diff --git a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj index c844e157e4..903a0e1b23 100644 --- a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj +++ b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj @@ -470,6 +470,7 @@ <ClInclude Include="$(SolutionDir)\..\src\core\ext\census\tracing.h" /> <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\max_age\max_age_filter.h" /> <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.h" /> + <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.h" /> </ItemGroup> <ItemGroup> <ClCompile Include="$(SolutionDir)\..\src\core\lib\surface\init.c"> @@ -886,6 +887,8 @@ </ClCompile> <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.c"> </ClCompile> + <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.c"> + </ClCompile> <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_unsecure_plugin_registry.c"> </ClCompile> </ItemGroup> diff --git a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters index 43d27b44a2..111e2418b6 100644 --- a/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters +++ b/vsprojects/vcxproj/grpc_unsecure/grpc_unsecure.vcxproj.filters @@ -622,6 +622,9 @@ <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.c"> <Filter>src\core\ext\filters\message_size</Filter> </ClCompile> + <ClCompile Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.c"> + <Filter>src\core\ext\filters\workarounds</Filter> + </ClCompile> <ClCompile Include="$(SolutionDir)\..\src\core\plugin_registry\grpc_unsecure_plugin_registry.c"> <Filter>src\core\plugin_registry</Filter> </ClCompile> @@ -1259,6 +1262,9 @@ <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\message_size\message_size_filter.h"> <Filter>src\core\ext\filters\message_size</Filter> </ClInclude> + <ClInclude Include="$(SolutionDir)\..\src\core\ext\filters\workarounds\workaround_cronet_compression_filter.h"> + <Filter>src\core\ext\filters\workarounds</Filter> + </ClInclude> </ItemGroup> <ItemGroup> @@ -1358,6 +1364,9 @@ <Filter Include="src\core\ext\filters\message_size"> <UniqueIdentifier>{8cbe7444-caac-49dc-be89-d4c4d1c7966a}</UniqueIdentifier> </Filter> + <Filter Include="src\core\ext\filters\workarounds"> + <UniqueIdentifier>{8bd0612e-bd53-c9e6-7b3c-20937e4e1e9e}</UniqueIdentifier> + </Filter> <Filter Include="src\core\ext\transport"> <UniqueIdentifier>{967c89fe-c97c-27e2-aac0-9ba5854cb5fa}</UniqueIdentifier> </Filter> |