Compare commits
29 Commits
rawhide
...
main-riscv
Author | SHA1 | Date | |
---|---|---|---|
af07139214 | |||
bd0ebd3160 | |||
af31b22f27 | |||
41ae9152d0 | |||
|
3e3af28488 | ||
|
3cf17c14e7 | ||
c3c55ba565 | |||
|
0b6a412abb | ||
|
a4b70e8b10 | ||
|
153fc86619 | ||
|
6ffb77b4fe | ||
|
a37ed8d6ef | ||
|
1ff9e62096 | ||
|
261f085537 | ||
|
c3aa71ba16 | ||
|
a6b8592585 | ||
|
8bf11b8c20 | ||
|
0e0dfcd9f7 | ||
|
4551c62449 | ||
|
f47cc5775e | ||
|
fbf88c1f82 | ||
|
e546f93f17 | ||
|
69df6c8acf | ||
|
c950d6032f | ||
|
332a1df40f | ||
|
faae750b3c | ||
|
edb6ee4683 | ||
|
b11af42482 | ||
|
33b1e5c01a |
145
0001-Specify-noexcept-for-cdef-functions.patch
Normal file
145
0001-Specify-noexcept-for-cdef-functions.patch
Normal file
@ -0,0 +1,145 @@
|
||||
From 45d31dba83999638808891ee7bf93638106bdb71 Mon Sep 17 00:00:00 2001
|
||||
From: Atri Bhattacharya <badshah400@gmail.com>
|
||||
Date: Thu, 7 Sep 2023 07:06:56 +0200
|
||||
Subject: [PATCH] Specify noexcept for cdef functions.
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
To build against cython 3.0, cdef functions that do not raise exceptions
|
||||
need to be explicitly declared as noexcept. Fixes issue #33918.
|
||||
|
||||
Co-Authored-By: Miro Hrončok <miro@hroncok.cz>
|
||||
---
|
||||
.../grpc/_cython/_cygrpc/aio/callback_common.pxd.pxi | 2 +-
|
||||
.../grpc/_cython/_cygrpc/aio/callback_common.pyx.pxi | 2 +-
|
||||
.../grpcio/grpc/_cython/_cygrpc/credentials.pyx.pxi | 2 +-
|
||||
.../grpcio/grpc/_cython/_cygrpc/fork_posix.pxd.pxi | 12 ++++++------
|
||||
.../grpcio/grpc/_cython/_cygrpc/fork_posix.pyx.pxi | 6 +++---
|
||||
.../grpcio/grpc/_cython/_cygrpc/vtable.pyx.pxi | 6 +++---
|
||||
6 files changed, 15 insertions(+), 15 deletions(-)
|
||||
|
||||
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pxd.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pxd.pxi
|
||||
index e54e510..26edbdb 100644
|
||||
--- a/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pxd.pxi
|
||||
+++ b/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pxd.pxi
|
||||
@@ -48,7 +48,7 @@ cdef class CallbackWrapper:
|
||||
@staticmethod
|
||||
cdef void functor_run(
|
||||
grpc_completion_queue_functor* functor,
|
||||
- int succeed)
|
||||
+ int succeed) noexcept
|
||||
|
||||
cdef grpc_completion_queue_functor *c_functor(self)
|
||||
|
||||
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pyx.pxi
|
||||
index f2d94a9..5dda90a 100644
|
||||
--- a/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pyx.pxi
|
||||
+++ b/src/python/grpcio/grpc/_cython/_cygrpc/aio/callback_common.pyx.pxi
|
||||
@@ -50,7 +50,7 @@ cdef class CallbackWrapper:
|
||||
@staticmethod
|
||||
cdef void functor_run(
|
||||
grpc_completion_queue_functor* functor,
|
||||
- int success):
|
||||
+ int success) noexcept:
|
||||
cdef CallbackContext *context = <CallbackContext *>functor
|
||||
cdef object waiter = <object>context.waiter
|
||||
if not waiter.cancelled():
|
||||
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/credentials.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/credentials.pyx.pxi
|
||||
index 23de3a0..52071f5 100644
|
||||
--- a/src/python/grpcio/grpc/_cython/_cygrpc/credentials.pyx.pxi
|
||||
+++ b/src/python/grpcio/grpc/_cython/_cygrpc/credentials.pyx.pxi
|
||||
@@ -314,7 +314,7 @@ def server_credentials_ssl_dynamic_cert_config(initial_cert_config,
|
||||
return credentials
|
||||
|
||||
cdef grpc_ssl_certificate_config_reload_status _server_cert_config_fetcher_wrapper(
|
||||
- void* user_data, grpc_ssl_server_certificate_config **config) with gil:
|
||||
+ void* user_data, grpc_ssl_server_certificate_config **config) noexcept with gil:
|
||||
# This is a credentials.ServerCertificateConfig
|
||||
cdef ServerCertificateConfig cert_config = None
|
||||
if not user_data:
|
||||
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pxd.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pxd.pxi
|
||||
index a925bdd..5e97a6d 100644
|
||||
--- a/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pxd.pxi
|
||||
+++ b/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pxd.pxi
|
||||
@@ -15,15 +15,15 @@
|
||||
|
||||
cdef extern from "pthread.h" nogil:
|
||||
int pthread_atfork(
|
||||
- void (*prepare)() nogil,
|
||||
- void (*parent)() nogil,
|
||||
- void (*child)() nogil)
|
||||
+ void (*prepare)() noexcept nogil,
|
||||
+ void (*parent)() noexcept nogil,
|
||||
+ void (*child)() noexcept nogil) noexcept
|
||||
|
||||
|
||||
-cdef void __prefork() nogil
|
||||
+cdef void __prefork() noexcept nogil
|
||||
|
||||
|
||||
-cdef void __postfork_parent() nogil
|
||||
+cdef void __postfork_parent() noexcept nogil
|
||||
|
||||
|
||||
-cdef void __postfork_child() nogil
|
||||
\ No newline at end of file
|
||||
+cdef void __postfork_child() noexcept nogil
|
||||
\ No newline at end of file
|
||||
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pyx.pxi
|
||||
index 53657e8..d4d1cff 100644
|
||||
--- a/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pyx.pxi
|
||||
+++ b/src/python/grpcio/grpc/_cython/_cygrpc/fork_posix.pyx.pxi
|
||||
@@ -34,7 +34,7 @@ _GRPC_ENABLE_FORK_SUPPORT = (
|
||||
|
||||
_fork_handler_failed = False
|
||||
|
||||
-cdef void __prefork() nogil:
|
||||
+cdef void __prefork() noexcept nogil:
|
||||
with gil:
|
||||
global _fork_handler_failed
|
||||
_fork_handler_failed = False
|
||||
@@ -48,14 +48,14 @@ cdef void __prefork() nogil:
|
||||
_fork_handler_failed = True
|
||||
|
||||
|
||||
-cdef void __postfork_parent() nogil:
|
||||
+cdef void __postfork_parent() noexcept nogil:
|
||||
with gil:
|
||||
with _fork_state.fork_in_progress_condition:
|
||||
_fork_state.fork_in_progress = False
|
||||
_fork_state.fork_in_progress_condition.notify_all()
|
||||
|
||||
|
||||
-cdef void __postfork_child() nogil:
|
||||
+cdef void __postfork_child() noexcept nogil:
|
||||
with gil:
|
||||
try:
|
||||
if _fork_handler_failed:
|
||||
diff --git a/src/python/grpcio/grpc/_cython/_cygrpc/vtable.pyx.pxi b/src/python/grpcio/grpc/_cython/_cygrpc/vtable.pyx.pxi
|
||||
index da4b81b..f594100 100644
|
||||
--- a/src/python/grpcio/grpc/_cython/_cygrpc/vtable.pyx.pxi
|
||||
+++ b/src/python/grpcio/grpc/_cython/_cygrpc/vtable.pyx.pxi
|
||||
@@ -13,16 +13,16 @@
|
||||
# limitations under the License.
|
||||
|
||||
# TODO(https://github.com/grpc/grpc/issues/15662): Reform this.
|
||||
-cdef void* _copy_pointer(void* pointer):
|
||||
+cdef void* _copy_pointer(void* pointer) noexcept:
|
||||
return pointer
|
||||
|
||||
|
||||
# TODO(https://github.com/grpc/grpc/issues/15662): Reform this.
|
||||
-cdef void _destroy_pointer(void* pointer):
|
||||
+cdef void _destroy_pointer(void* pointer) noexcept:
|
||||
pass
|
||||
|
||||
|
||||
-cdef int _compare_pointer(void* first_pointer, void* second_pointer):
|
||||
+cdef int _compare_pointer(void* first_pointer, void* second_pointer) noexcept:
|
||||
if first_pointer < second_pointer:
|
||||
return -1
|
||||
elif first_pointer > second_pointer:
|
||||
--
|
||||
2.41.0
|
||||
|
695
0001-http2-Dont-drop-connections-on-metadata-limit-exceed.patch
Normal file
695
0001-http2-Dont-drop-connections-on-metadata-limit-exceed.patch
Normal file
@ -0,0 +1,695 @@
|
||||
From 9f01fd62c356c05d14abbaebfcedf0b387d1cb96 Mon Sep 17 00:00:00 2001
|
||||
From: Craig Tiller <ctiller@google.com>
|
||||
Date: Tue, 7 Feb 2023 08:27:04 -0800
|
||||
Subject: [PATCH] [http2] Dont drop connections on metadata limit exceeded
|
||||
(#32309)
|
||||
|
||||
* [http] Dont drop connections on metadata limit exceeded
|
||||
|
||||
* remove bad test
|
||||
|
||||
* Automated change: Fix sanity tests
|
||||
|
||||
---------
|
||||
|
||||
Co-authored-by: ctiller <ctiller@users.noreply.github.com>
|
||||
---
|
||||
CMakeLists.txt | 38 ---
|
||||
build_autogenerated.yaml | 13 -
|
||||
.../chttp2/transport/hpack_parser.cc | 11 +-
|
||||
.../ext/transport/chttp2/transport/internal.h | 2 -
|
||||
.../ext/transport/chttp2/transport/parsing.cc | 6 +-
|
||||
test/core/bad_client/generate_tests.bzl | 1 -
|
||||
test/core/bad_client/tests/large_metadata.cc | 108 ---------
|
||||
.../bad_client/tests/large_metadata.headers | 106 --------
|
||||
test/core/end2end/tests/large_metadata.cc | 226 +++++++++---------
|
||||
tools/run_tests/generated/tests.json | 24 --
|
||||
10 files changed, 126 insertions(+), 409 deletions(-)
|
||||
delete mode 100644 test/core/bad_client/tests/large_metadata.cc
|
||||
delete mode 100644 test/core/bad_client/tests/large_metadata.headers
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 1ecaea8eb7..661ce2c511 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -1078,7 +1078,6 @@ if(gRPC_BUILD_TESTS)
|
||||
add_dependencies(buildtests_cxx istio_echo_server_test)
|
||||
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)
|
||||
@@ -12796,43 +12795,6 @@ target_link_libraries(json_test
|
||||
)
|
||||
|
||||
|
||||
-endif()
|
||||
-if(gRPC_BUILD_TESTS)
|
||||
-
|
||||
-add_executable(large_metadata_bad_client_test
|
||||
- test/core/bad_client/bad_client.cc
|
||||
- test/core/bad_client/tests/large_metadata.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(large_metadata_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(large_metadata_bad_client_test
|
||||
- ${_gRPC_PROTOBUF_LIBRARIES}
|
||||
- ${_gRPC_ALLTARGETS_LIBRARIES}
|
||||
- grpc_test_util
|
||||
-)
|
||||
-
|
||||
-
|
||||
endif()
|
||||
if(gRPC_BUILD_TESTS)
|
||||
|
||||
diff --git a/build_autogenerated.yaml b/build_autogenerated.yaml
|
||||
index 941a095cd1..9c2fbaf2b8 100644
|
||||
--- a/build_autogenerated.yaml
|
||||
+++ b/build_autogenerated.yaml
|
||||
@@ -6683,19 +6683,6 @@ targets:
|
||||
deps:
|
||||
- grpc_test_util
|
||||
uses_polling: false
|
||||
-- name: large_metadata_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/large_metadata.cc
|
||||
- - test/core/end2end/cq_verifier.cc
|
||||
- deps:
|
||||
- - grpc_test_util
|
||||
- name: latch_test
|
||||
gtest: true
|
||||
build: test
|
||||
diff --git a/src/core/ext/transport/chttp2/transport/hpack_parser.cc b/src/core/ext/transport/chttp2/transport/hpack_parser.cc
|
||||
index 5354338cba..314707b59e 100644
|
||||
--- a/src/core/ext/transport/chttp2/transport/hpack_parser.cc
|
||||
+++ b/src/core/ext/transport/chttp2/transport/hpack_parser.cc
|
||||
@@ -1218,12 +1218,17 @@ class HPackParser::Parser {
|
||||
"). GRPC_ARG_MAX_METADATA_SIZE can be set to increase this limit.",
|
||||
*frame_length_, metadata_size_limit_);
|
||||
if (metadata_buffer_ != nullptr) metadata_buffer_->Clear();
|
||||
+ // StreamId is used as a signal to skip this stream but keep the connection
|
||||
+ // alive
|
||||
return input_->MaybeSetErrorAndReturn(
|
||||
[] {
|
||||
return grpc_error_set_int(
|
||||
- GRPC_ERROR_CREATE_FROM_STATIC_STRING(
|
||||
- "received initial metadata size exceeds limit"),
|
||||
- GRPC_ERROR_INT_GRPC_STATUS, GRPC_STATUS_RESOURCE_EXHAUSTED);
|
||||
+ grpc_error_set_int(
|
||||
+ GRPC_ERROR_CREATE_FROM_STATIC_STRING(
|
||||
+ "received initial metadata size exceeds limit"),
|
||||
+ GRPC_ERROR_INT_GRPC_STATUS,
|
||||
+ GRPC_STATUS_RESOURCE_EXHAUSTED),
|
||||
+ GRPC_ERROR_INT_STREAM_ID, 0);
|
||||
},
|
||||
false);
|
||||
}
|
||||
diff --git a/src/core/ext/transport/chttp2/transport/internal.h b/src/core/ext/transport/chttp2/transport/internal.h
|
||||
index 4af3c4ec9d..e01cff72c1 100644
|
||||
--- a/src/core/ext/transport/chttp2/transport/internal.h
|
||||
+++ b/src/core/ext/transport/chttp2/transport/internal.h
|
||||
@@ -541,8 +541,6 @@ struct grpc_chttp2_stream {
|
||||
|
||||
grpc_core::Timestamp deadline = grpc_core::Timestamp::InfFuture();
|
||||
|
||||
- /** saw some stream level error */
|
||||
- grpc_error_handle forced_close_error = GRPC_ERROR_NONE;
|
||||
/** how many header frames have we received? */
|
||||
uint8_t header_frames_received = 0;
|
||||
/** number of bytes received - reset at end of parse thread execution */
|
||||
diff --git a/src/core/ext/transport/chttp2/transport/parsing.cc b/src/core/ext/transport/chttp2/transport/parsing.cc
|
||||
index 6a45381e54..48dddc9313 100644
|
||||
--- a/src/core/ext/transport/chttp2/transport/parsing.cc
|
||||
+++ b/src/core/ext/transport/chttp2/transport/parsing.cc
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <string.h>
|
||||
|
||||
#include <string>
|
||||
+#include <utility>
|
||||
|
||||
#include "absl/base/attributes.h"
|
||||
#include "absl/status/status.h"
|
||||
@@ -675,10 +676,7 @@ static grpc_error_handle parse_frame_slice(grpc_chttp2_transport* t,
|
||||
}
|
||||
grpc_chttp2_parsing_become_skip_parser(t);
|
||||
if (s) {
|
||||
- s->forced_close_error = err;
|
||||
- grpc_chttp2_add_rst_stream_to_next_write(t, t->incoming_stream_id,
|
||||
- GRPC_HTTP2_PROTOCOL_ERROR,
|
||||
- &s->stats.outgoing);
|
||||
+ grpc_chttp2_cancel_stream(t, s, std::exchange(err, absl::OkStatus()));
|
||||
} else {
|
||||
GRPC_ERROR_UNREF(err);
|
||||
}
|
||||
diff --git a/test/core/bad_client/generate_tests.bzl b/test/core/bad_client/generate_tests.bzl
|
||||
index 85aafed655..6100d142d6 100755
|
||||
--- a/test/core/bad_client/generate_tests.bzl
|
||||
+++ b/test/core/bad_client/generate_tests.bzl
|
||||
@@ -29,7 +29,6 @@ BAD_CLIENT_TESTS = {
|
||||
"headers": test_options(),
|
||||
"initial_settings_frame": test_options(),
|
||||
"head_of_line_blocking": test_options(),
|
||||
- "large_metadata": test_options(),
|
||||
"out_of_bounds": test_options(),
|
||||
"server_registered_method": test_options(),
|
||||
"simple_request": test_options(),
|
||||
diff --git a/test/core/bad_client/tests/large_metadata.cc b/test/core/bad_client/tests/large_metadata.cc
|
||||
deleted file mode 100644
|
||||
index 9423dc3f6d..0000000000
|
||||
--- a/test/core/bad_client/tests/large_metadata.cc
|
||||
+++ /dev/null
|
||||
@@ -1,108 +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 <string.h>
|
||||
-
|
||||
-#include "absl/strings/str_format.h"
|
||||
-#include "absl/strings/str_join.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
|
||||
-// actually appended to this in a single string, since the string would
|
||||
-// be longer than the C99 string literal limit. Instead, we dynamically
|
||||
-// construct it by adding the large headers one at a time.
|
||||
-
|
||||
-/* headers: generated from large_metadata.headers in this directory */
|
||||
-#define PFX_TOO_MUCH_METADATA_FROM_CLIENT_REQUEST \
|
||||
- "\x00\x00\x00\x04\x01\x00\x00\x00\x00" \
|
||||
- "\x00" \
|
||||
- "5{\x01\x05\x00\x00\x00\x01" \
|
||||
- "\x10\x05:path\x08/foo/bar" \
|
||||
- "\x10\x07:scheme\x04http" \
|
||||
- "\x10\x07:method\x04POST" \
|
||||
- "\x10\x0a:authority\x09localhost" \
|
||||
- "\x10\x0c" \
|
||||
- "content-type\x10" \
|
||||
- "application/grpc" \
|
||||
- "\x10\x14grpc-accept-encoding\x15identity,deflate,gzip" \
|
||||
- "\x10\x02te\x08trailers" \
|
||||
- "\x10\x0auser-agent\"bad-client grpc-c/0.12.0.0 (linux)"
|
||||
-
|
||||
-// Each large-metadata header is constructed from these start and end
|
||||
-// strings, with a two-digit number in between.
|
||||
-#define PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_START_STR "\x10\x0duser-header"
|
||||
-#define PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_END_STR \
|
||||
- "~aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" \
|
||||
- "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
|
||||
-
|
||||
-// The size of each large-metadata header string.
|
||||
-#define PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_SIZE \
|
||||
- ((sizeof(PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_START_STR) - 1) + 2 + \
|
||||
- (sizeof(PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_END_STR) - 1))
|
||||
-
|
||||
-// The number of headers we're adding and the total size of the client
|
||||
-// payload.
|
||||
-#define NUM_HEADERS 46
|
||||
-#define TOO_MUCH_METADATA_FROM_CLIENT_REQUEST_SIZE \
|
||||
- ((sizeof(PFX_TOO_MUCH_METADATA_FROM_CLIENT_REQUEST) - 1) + \
|
||||
- (NUM_HEADERS * PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_SIZE) + 1)
|
||||
-
|
||||
-static void verifier_fails(grpc_server* server, grpc_completion_queue* cq,
|
||||
- void* /*registered_method*/) {
|
||||
- while (grpc_core::Server::FromC(server)->HasOpenConnections()) {
|
||||
- GPR_ASSERT(grpc_completion_queue_next(
|
||||
- cq, grpc_timeout_milliseconds_to_deadline(20), nullptr)
|
||||
- .type == GRPC_QUEUE_TIMEOUT);
|
||||
- }
|
||||
-}
|
||||
-
|
||||
-int main(int argc, char** argv) {
|
||||
- int i;
|
||||
- grpc_init();
|
||||
- grpc::testing::TestEnvironment env(&argc, argv);
|
||||
-
|
||||
- // Test sending more metadata than the server will accept.
|
||||
- std::vector<std::string> headers;
|
||||
- for (i = 0; i < NUM_HEADERS; ++i) {
|
||||
- headers.push_back(absl::StrFormat(
|
||||
- "%s%02d%s", PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_START_STR, i,
|
||||
- PFX_TOO_MUCH_METADATA_FROM_CLIENT_HEADER_END_STR));
|
||||
- }
|
||||
- std::string client_headers = absl::StrJoin(headers, "");
|
||||
- char client_payload[TOO_MUCH_METADATA_FROM_CLIENT_REQUEST_SIZE] =
|
||||
- PFX_TOO_MUCH_METADATA_FROM_CLIENT_REQUEST;
|
||||
- memcpy(client_payload + sizeof(PFX_TOO_MUCH_METADATA_FROM_CLIENT_REQUEST) - 1,
|
||||
- client_headers.data(), client_headers.size());
|
||||
- grpc_bad_client_arg args[2];
|
||||
- args[0] = connection_preface_arg;
|
||||
- args[1].client_validator = rst_stream_client_validator;
|
||||
- args[1].client_payload = client_payload;
|
||||
- args[1].client_payload_length = sizeof(client_payload) - 1;
|
||||
-
|
||||
- grpc_run_bad_client_test(verifier_fails, args, 2, 0);
|
||||
-
|
||||
- grpc_shutdown();
|
||||
- return 0;
|
||||
-}
|
||||
diff --git a/test/core/bad_client/tests/large_metadata.headers b/test/core/bad_client/tests/large_metadata.headers
|
||||
deleted file mode 100644
|
||||
index 75de3ef100..0000000000
|
||||
--- a/test/core/bad_client/tests/large_metadata.headers
|
||||
+++ /dev/null
|
||||
@@ -1,106 +0,0 @@
|
||||
-# headers used in simple_request.c
|
||||
-# use tools/codegen/core/gen_header_frame.py --set_end_stream to generate
|
||||
-# the binary strings contained in the source code
|
||||
-:path: /foo/bar
|
||||
-:scheme: http
|
||||
-:method: POST
|
||||
-:authority: localhost
|
||||
-content-type: application/grpc
|
||||
-grpc-accept-encoding: identity,deflate,gzip
|
||||
-te: trailers
|
||||
-user-agent: bad-client grpc-c/0.12.0.0 (linux)
|
||||
-user-header00: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
-user-header01: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
-user-header02: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
-user-header03: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa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aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
-user-header93: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
-user-header94: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
diff --git a/test/core/end2end/tests/large_metadata.cc b/test/core/end2end/tests/large_metadata.cc
|
||||
index 72cf519899..08cd20cb4f 100644
|
||||
--- a/test/core/end2end/tests/large_metadata.cc
|
||||
+++ b/test/core/end2end/tests/large_metadata.cc
|
||||
@@ -247,10 +247,6 @@ static void test_request_with_large_metadata(grpc_end2end_test_config config) {
|
||||
// Server responds with metadata larger than what the client accepts.
|
||||
static void test_request_with_bad_large_metadata_response(
|
||||
grpc_end2end_test_config config) {
|
||||
- grpc_call* c;
|
||||
- grpc_call* s;
|
||||
- grpc_metadata meta;
|
||||
- const size_t large_size = 64 * 1024;
|
||||
grpc_arg arg;
|
||||
arg.type = GRPC_ARG_INTEGER;
|
||||
arg.key = const_cast<char*>(GRPC_ARG_MAX_METADATA_SIZE);
|
||||
@@ -259,115 +255,125 @@ static void test_request_with_bad_large_metadata_response(
|
||||
grpc_end2end_test_fixture f = begin_test(
|
||||
config, "test_request_with_bad_large_metadata_response", &args, &args);
|
||||
cq_verifier* cqv = cq_verifier_create(f.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_call_details call_details;
|
||||
- grpc_status_code status;
|
||||
- grpc_call_error error;
|
||||
- grpc_slice details;
|
||||
- int was_cancelled = 2;
|
||||
-
|
||||
- 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);
|
||||
-
|
||||
- meta.key = grpc_slice_from_static_string("key");
|
||||
- meta.value = grpc_slice_malloc(large_size);
|
||||
- memset(GRPC_SLICE_START_PTR(meta.value), 'a', large_size);
|
||||
-
|
||||
- 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));
|
||||
- // Client: send request.
|
||||
- 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->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));
|
||||
- // Server: send large initial metadata
|
||||
- op = ops;
|
||||
- op->op = GRPC_OP_SEND_INITIAL_METADATA;
|
||||
- op->data.send_initial_metadata.count = 1;
|
||||
- op->data.send_initial_metadata.metadata = &meta;
|
||||
- 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++;
|
||||
- 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++;
|
||||
- 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(status == GRPC_STATUS_RESOURCE_EXHAUSTED);
|
||||
- GPR_ASSERT(0 == grpc_slice_str_cmp(
|
||||
- details, "received initial metadata size exceeds limit"));
|
||||
- GPR_ASSERT(0 == grpc_slice_str_cmp(call_details.method, "/foo"));
|
||||
-
|
||||
- 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);
|
||||
|
||||
+ for (int i = 0; i < 10; i++) {
|
||||
+ grpc_call* c;
|
||||
+ grpc_call* s;
|
||||
+ grpc_metadata meta;
|
||||
+ const size_t large_size = 64 * 1024;
|
||||
+ 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;
|
||||
+ grpc_call_error error;
|
||||
+ grpc_slice details;
|
||||
+ int was_cancelled = 2;
|
||||
+
|
||||
+ 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);
|
||||
+
|
||||
+ meta.key = grpc_slice_from_static_string("key");
|
||||
+ meta.value = grpc_slice_malloc(large_size);
|
||||
+ memset(GRPC_SLICE_START_PTR(meta.value), 'a', large_size);
|
||||
+
|
||||
+ 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));
|
||||
+ // Client: send request.
|
||||
+ 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->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));
|
||||
+ // Server: send large initial metadata
|
||||
+ op = ops;
|
||||
+ op->op = GRPC_OP_SEND_INITIAL_METADATA;
|
||||
+ op->data.send_initial_metadata.count = 1;
|
||||
+ op->data.send_initial_metadata.metadata = &meta;
|
||||
+ 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++;
|
||||
+ 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++;
|
||||
+ 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(status == GRPC_STATUS_RESOURCE_EXHAUSTED);
|
||||
+ const char* expected_error = "received initial metadata size exceeds limit";
|
||||
+ grpc_slice actual_error =
|
||||
+ grpc_slice_split_head(&details, strlen(expected_error));
|
||||
+ GPR_ASSERT(0 == grpc_slice_str_cmp(actual_error, expected_error));
|
||||
+ GPR_ASSERT(0 == grpc_slice_str_cmp(call_details.method, "/foo"));
|
||||
+
|
||||
+ grpc_slice_unref(actual_error);
|
||||
+ 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);
|
||||
+
|
||||
+ grpc_slice_unref(meta.value);
|
||||
+ }
|
||||
cq_verifier_destroy(cqv);
|
||||
|
||||
- grpc_slice_unref(meta.value);
|
||||
-
|
||||
end_test(&f);
|
||||
config.tear_down_data(&f);
|
||||
}
|
||||
diff --git a/tools/run_tests/generated/tests.json b/tools/run_tests/generated/tests.json
|
||||
index 9f21710575..0cf8b37e76 100644
|
||||
--- a/tools/run_tests/generated/tests.json
|
||||
+++ b/tools/run_tests/generated/tests.json
|
||||
@@ -5087,30 +5087,6 @@
|
||||
],
|
||||
"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": "large_metadata_bad_client_test",
|
||||
- "platforms": [
|
||||
- "linux",
|
||||
- "mac",
|
||||
- "posix",
|
||||
- "windows"
|
||||
- ],
|
||||
- "uses_polling": true
|
||||
- },
|
||||
{
|
||||
"args": [],
|
||||
"benchmark": false,
|
||||
--
|
||||
2.41.0
|
||||
|
40
34857.patch
Normal file
40
34857.patch
Normal file
@ -0,0 +1,40 @@
|
||||
From d583a79750a7f3cf2c955d880ebfbfd5b8aa1675 Mon Sep 17 00:00:00 2001
|
||||
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
|
||||
Date: Thu, 2 Nov 2023 07:00:37 -0400
|
||||
Subject: [PATCH] [Python] Do not call PyEval_InitThreads
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Since Python 3.7, it’s called by Py_Initialize and doesn’t need to be called manually, so this removal has no effect.
|
||||
|
||||
Since Python 3.9, it does nothing, and in Python 3.13, it will be removed, which makes this change necessary.
|
||||
|
||||
References:
|
||||
|
||||
https://docs.python.org/3/c-api/init.html#c.PyEval_InitThreads
|
||||
|
||||
https://github.com/python/cpython/issues/105182
|
||||
---
|
||||
src/python/grpcio/grpc/_cython/cygrpc.pyx | 7 -------
|
||||
1 file changed, 7 deletions(-)
|
||||
|
||||
diff --git a/src/python/grpcio/grpc/_cython/cygrpc.pyx b/src/python/grpcio/grpc/_cython/cygrpc.pyx
|
||||
index 2fd2347352a27..3b6ae9281139d 100644
|
||||
--- a/src/python/grpcio/grpc/_cython/cygrpc.pyx
|
||||
+++ b/src/python/grpcio/grpc/_cython/cygrpc.pyx
|
||||
@@ -80,14 +80,7 @@ include "_cygrpc/aio/server.pyx.pxi"
|
||||
#
|
||||
# initialize gRPC
|
||||
#
|
||||
-cdef extern from "Python.h":
|
||||
-
|
||||
- int PyEval_InitThreads()
|
||||
-
|
||||
cdef _initialize():
|
||||
- # We have Python callbacks called by c-core threads, this ensures the GIL
|
||||
- # is initialized.
|
||||
- PyEval_InitThreads()
|
||||
grpc_set_ssl_roots_override_callback(
|
||||
<grpc_ssl_roots_override_callback>ssl_roots_override_callback)
|
||||
|
117
grpc-1.48.4-abseil-cpp-includes.patch
Normal file
117
grpc-1.48.4-abseil-cpp-includes.patch
Normal file
@ -0,0 +1,117 @@
|
||||
From a133d644138b6018b5df2bcb4bba07211a9ac5b7 Mon Sep 17 00:00:00 2001
|
||||
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
|
||||
Date: Wed, 17 Jan 2024 21:43:39 -0500
|
||||
Subject: [PATCH 1/3] Add some missing #includes for absl/strings/str_cat.h
|
||||
|
||||
Partial backport of a giant IWYU commit:
|
||||
|
||||
https://github.com/grpc/grpc/commit/8174a75079bc00aec4f80e3cd9f91a7042073ca8
|
||||
|
||||
Needed for abseil-cpp-20240116.rc1 compatibility.
|
||||
---
|
||||
test/core/address_utils/sockaddr_utils_test.cc | 1 +
|
||||
test/core/channel/call_finalization_test.cc | 1 +
|
||||
test/core/json/json_test.cc | 1 +
|
||||
3 files changed, 3 insertions(+)
|
||||
|
||||
diff --git a/test/core/address_utils/sockaddr_utils_test.cc b/test/core/address_utils/sockaddr_utils_test.cc
|
||||
index 3ecb5a7f82..e071d94e41 100644
|
||||
--- a/test/core/address_utils/sockaddr_utils_test.cc
|
||||
+++ b/test/core/address_utils/sockaddr_utils_test.cc
|
||||
@@ -24,6 +24,7 @@
|
||||
#include <sys/un.h>
|
||||
#endif
|
||||
|
||||
+#include "absl/strings/str_cat.h"
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include <grpc/grpc.h>
|
||||
diff --git a/test/core/channel/call_finalization_test.cc b/test/core/channel/call_finalization_test.cc
|
||||
index 61d92c5f56..0ff7a00cff 100644
|
||||
--- a/test/core/channel/call_finalization_test.cc
|
||||
+++ b/test/core/channel/call_finalization_test.cc
|
||||
@@ -14,6 +14,7 @@
|
||||
|
||||
#include "src/core/lib/channel/call_finalization.h"
|
||||
|
||||
+#include "absl/strings/str_cat.h"
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
#include "src/core/lib/resource_quota/resource_quota.h"
|
||||
diff --git a/test/core/json/json_test.cc b/test/core/json/json_test.cc
|
||||
index 232caca9ba..ff26b7ee75 100644
|
||||
--- a/test/core/json/json_test.cc
|
||||
+++ b/test/core/json/json_test.cc
|
||||
@@ -20,6 +20,7 @@
|
||||
|
||||
#include <string.h>
|
||||
|
||||
+#include "absl/strings/str_cat.h"
|
||||
#include <gmock/gmock.h>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
--
|
||||
2.43.0
|
||||
|
||||
|
||||
From 9f2762981680094d97a6092e76c8b94309df9512 Mon Sep 17 00:00:00 2001
|
||||
From: Esun Kim <veblush@google.com>
|
||||
Date: Thu, 14 Sep 2023 17:25:41 -0700
|
||||
Subject: [PATCH 2/3] [Fix] Added missing #include (#34359)
|
||||
|
||||
One more missing #include
|
||||
---
|
||||
test/core/tsi/crl_ssl_transport_security_test.cc | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/test/core/tsi/crl_ssl_transport_security_test.cc b/test/core/tsi/crl_ssl_transport_security_test.cc
|
||||
index 5e4dc1b57e..dd33173abf 100644
|
||||
--- a/test/core/tsi/crl_ssl_transport_security_test.cc
|
||||
+++ b/test/core/tsi/crl_ssl_transport_security_test.cc
|
||||
@@ -19,6 +19,8 @@
|
||||
#include <gmock/gmock.h>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
+#include "absl/strings/str_cat.h"
|
||||
+
|
||||
#include <grpc/grpc.h>
|
||||
#include <grpc/support/alloc.h>
|
||||
#include <grpc/support/log.h>
|
||||
--
|
||||
2.43.0
|
||||
|
||||
|
||||
From 8a53ca0b02de4074763ec970c85ab9594d99532c Mon Sep 17 00:00:00 2001
|
||||
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
|
||||
Date: Thu, 18 Jan 2024 08:07:10 -0500
|
||||
Subject: [PATCH 3/3] Add abseil includes in test/cpp/end2end/xds/xds_server.h
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
This follows the IWYU “philosophy,” but the necessary includes were
|
||||
found and added manually.
|
||||
|
||||
Needed for compatibility with abseil-cpp 20240116.rc1.
|
||||
---
|
||||
test/cpp/end2end/xds/xds_server.h | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/test/cpp/end2end/xds/xds_server.h b/test/cpp/end2end/xds/xds_server.h
|
||||
index 066629b101..4499af1a8d 100644
|
||||
--- a/test/cpp/end2end/xds/xds_server.h
|
||||
+++ b/test/cpp/end2end/xds/xds_server.h
|
||||
@@ -26,6 +26,10 @@
|
||||
#include <gmock/gmock.h>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
+#include "absl/status/status.h"
|
||||
+#include "absl/strings/numbers.h"
|
||||
+#include "absl/strings/string_view.h"
|
||||
+#include "absl/time/time.h"
|
||||
#include "absl/types/optional.h"
|
||||
|
||||
#include <grpc/support/log.h>
|
||||
--
|
||||
2.43.0
|
||||
|
71
grpc-1.48.4-find_module.patch
Normal file
71
grpc-1.48.4-find_module.patch
Normal file
@ -0,0 +1,71 @@
|
||||
From 01d7101b39dd9049ae3cb9c30195b42ed9c76579 Mon Sep 17 00:00:00 2001
|
||||
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
|
||||
Date: Tue, 20 Jun 2023 11:36:40 -0400
|
||||
Subject: [PATCH 1/2] Do not use importlib find_module API
|
||||
|
||||
This API was removed in Python 3.12
|
||||
(https://github.com/python/cpython/issues/98040).
|
||||
|
||||
Fixes Python 3.12 support in grpcio tests.
|
||||
---
|
||||
src/python/grpcio_tests/tests/_loader.py | 4 +++-
|
||||
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/python/grpcio_tests/tests/_loader.py b/src/python/grpcio_tests/tests/_loader.py
|
||||
index 80c107aa8e..c497a9aabd 100644
|
||||
--- a/src/python/grpcio_tests/tests/_loader.py
|
||||
+++ b/src/python/grpcio_tests/tests/_loader.py
|
||||
@@ -71,7 +71,9 @@ class Loader(object):
|
||||
"""
|
||||
for importer, module_name, is_package in (
|
||||
pkgutil.walk_packages(package_paths)):
|
||||
- module = importer.find_module(module_name).load_module(module_name)
|
||||
+ spec = importer.find_spec(module_name)
|
||||
+ module = importlib.util.module_from_spec(spec)
|
||||
+ spec.loader.exec_module(module)
|
||||
self.visit_module(module)
|
||||
|
||||
def visit_module(self, module):
|
||||
--
|
||||
2.40.1
|
||||
|
||||
|
||||
From a7191f6781674340740896d5a284ab856e596b2e Mon Sep 17 00:00:00 2001
|
||||
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
|
||||
Date: Tue, 20 Jun 2023 12:38:23 -0400
|
||||
Subject: [PATCH 2/2] More importlib find_module migration
|
||||
|
||||
Do not use importlib find_module API in bazel/_gevent_test_main.py
|
||||
|
||||
This API was removed in Python 3.12
|
||||
(https://github.com/python/cpython/issues/98040).
|
||||
---
|
||||
bazel/_gevent_test_main.py | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/bazel/_gevent_test_main.py b/bazel/_gevent_test_main.py
|
||||
index f7936daaf0..bec31a911b 100644
|
||||
--- a/bazel/_gevent_test_main.py
|
||||
+++ b/bazel/_gevent_test_main.py
|
||||
@@ -42,6 +42,7 @@ import unittest
|
||||
import sys
|
||||
import os
|
||||
import pkgutil
|
||||
+import importlib
|
||||
|
||||
def trace_callback(event, args):
|
||||
if event in ("switch", "throw"):
|
||||
@@ -73,7 +74,9 @@ class SingleLoader(object):
|
||||
tests = []
|
||||
for importer, module_name, is_package in pkgutil.walk_packages([os.path.dirname(os.path.relpath(__file__))]):
|
||||
if pattern in module_name:
|
||||
- module = importer.find_module(module_name).load_module(module_name)
|
||||
+ spec = importer.find_spec(module_name)
|
||||
+ module = importlib.util.module_from_spec(spec)
|
||||
+ spec.loader.exec_module(module)
|
||||
tests.append(loader.loadTestsFromModule(module))
|
||||
if len(tests) != 1:
|
||||
raise AssertionError("Expected only 1 test module. Found {}".format(tests))
|
||||
--
|
||||
2.40.1
|
||||
|
30
grpc-1.48.4-wrap_socket.patch
Normal file
30
grpc-1.48.4-wrap_socket.patch
Normal file
@ -0,0 +1,30 @@
|
||||
From 15b168ffc762f99997c57a34c4cbb595697ede79 Mon Sep 17 00:00:00 2001
|
||||
From: "Benjamin A. Beasley" <code@musicinmybrain.net>
|
||||
Date: Tue, 20 Jun 2023 09:05:35 -0400
|
||||
Subject: [PATCH] Use ssl.SSLContext.wrap_socket, not ssl.wrap_socket
|
||||
|
||||
The latter emits a DeprecationWarning since Python 3.10 and is removed
|
||||
in Python 3.12.
|
||||
---
|
||||
test/core/http/test_server.py | 7 +++----
|
||||
1 file changed, 3 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/test/core/http/test_server.py b/test/core/http/test_server.py
|
||||
index abd26c53d3..7c01638d8b 100755
|
||||
--- a/test/core/http/test_server.py
|
||||
+++ b/test/core/http/test_server.py
|
||||
@@ -62,8 +62,7 @@ class Handler(BaseHTTPRequestHandler):
|
||||
|
||||
httpd = HTTPServer(('localhost', args.port), Handler)
|
||||
if args.ssl:
|
||||
- httpd.socket = ssl.wrap_socket(httpd.socket,
|
||||
- certfile=_PEM,
|
||||
- keyfile=_KEY,
|
||||
- server_side=True)
|
||||
+ ctx = ssl.SSLContext()
|
||||
+ ctx.load_cert_chain(certfile=_PEM, keyfile=_KEY)
|
||||
+ httpd.socket = ctx.wrap_socket(httpd.socket, server_side=True)
|
||||
httpd.serve_forever()
|
||||
--
|
||||
2.40.1
|
||||
|
108
grpc.spec
108
grpc.spec
@ -1,5 +1,5 @@
|
||||
# We need to use C++17 to link against the system abseil-cpp, or we get linker
|
||||
# errors.
|
||||
# We need to use C++17 to link against the system abseil-cpp, since it was
|
||||
# compiled with C++17 (an intentional abseil-cpp design decision).
|
||||
%global cpp_std 17
|
||||
|
||||
# However, we also get linker errors building the tests if we link against the
|
||||
@ -15,7 +15,7 @@
|
||||
%global gtest_commit 0e402173c97aea7a00749e825b194bfede4f2e45
|
||||
#global gtest_version 1.11.0
|
||||
#global gtest_dir googletest-release-#{gtest_version}
|
||||
%bcond_with system_gtest
|
||||
%bcond system_gtest 0
|
||||
|
||||
# =====
|
||||
|
||||
@ -65,11 +65,11 @@
|
||||
# This must be enabled to get grpc_cli, which is apparently considered part of
|
||||
# the tests by upstream. This is mentioned in
|
||||
# https://github.com/grpc/grpc/issues/23432.
|
||||
%bcond_without core_tests
|
||||
%bcond core_tests 1
|
||||
|
||||
# A great many of these tests (over 20%) fail. Any help in understanding these
|
||||
# well enough to fix them or report them upstream is welcome.
|
||||
%bcond_with python_aio_tests
|
||||
%bcond python_aio_tests 0
|
||||
|
||||
%ifnarch s390x
|
||||
# There are currently a significant number of failures like:
|
||||
@ -83,21 +83,21 @@
|
||||
# if not self.IsInitialized():
|
||||
# ^^^^^^^^^^^^^^^^^^
|
||||
# AttributeError: 'NoneType' object has no attribute 'IsInitialized'
|
||||
%bcond_with python_gevent_tests
|
||||
%bcond python_gevent_tests 0
|
||||
%else
|
||||
# A significant number of Python tests pass in test_lite but fail in
|
||||
# test_gevent, mostly by dumping core without a traceback. Since it is tedious
|
||||
# to enumerate these (and it is difficult to implement “suite-specific” skips
|
||||
# for shared tests, so the tests would have to be skipped in all suites), we
|
||||
# just skip the gevent suite entirely on this architecture.
|
||||
%bcond_with python_gevent_tests
|
||||
%bcond python_gevent_tests 0
|
||||
%endif
|
||||
|
||||
# Running core tests under valgrind may help debug crashes. This is mostly
|
||||
# ignored if the gdb build conditional is also set.
|
||||
%bcond_with valgrind
|
||||
%bcond valgrind 0
|
||||
# Running core tests under gdb may help debug crashes.
|
||||
%bcond_with gdb
|
||||
%bcond gdb 0
|
||||
|
||||
# HTML documentation generated with Doxygen and/or Sphinx is not suitable for
|
||||
# packaging due to a minified JavaScript bundle inserted by
|
||||
@ -117,7 +117,7 @@
|
||||
|
||||
Name: grpc
|
||||
Version: 1.48.4
|
||||
Release: %autorelease
|
||||
Release: %autorelease -e 1.riscv64
|
||||
Summary: RPC library and framework
|
||||
|
||||
%global srcversion %(echo '%{version}' | sed -r 's/~rc/-pre/')
|
||||
@ -214,6 +214,9 @@ BuildRequires: pkgconfig(protobuf)
|
||||
BuildRequires: protobuf-compiler
|
||||
BuildRequires: pkgconfig(re2)
|
||||
BuildRequires: pkgconfig(openssl)
|
||||
%if 0%{?fedora} >= 41
|
||||
BuildRequires: openssl-devel-engine
|
||||
%endif
|
||||
BuildRequires: cmake(c-ares)
|
||||
BuildRequires: abseil-cpp-devel
|
||||
# Sets XXH_INCLUDE_ALL, which means xxhash is used as a header-only library
|
||||
@ -253,7 +256,7 @@ BuildRequires: python3dist(six) >= 1.10
|
||||
# grpcio (setup.py) setup_requires (with GRPC_PYTHON_BUILD_WITH_CYTHON, or
|
||||
# absent generated sources); also needed for grpcio_tools
|
||||
# (tools/distrib/python/grpcio_tools/setup.py)
|
||||
BuildRequires: python3dist(cython) > 0.23
|
||||
BuildRequires: python3dist(cython) > 0.23
|
||||
|
||||
# grpcio (setup.py) install_requires:
|
||||
# grpcio_tests (src/python/grpcio_tests/setup.py) install_requires:
|
||||
@ -376,6 +379,60 @@ Patch: grpc-1.48.0-python-grpcio_tests-DynamicStubTest-hang.patch
|
||||
#
|
||||
# https://github.com/grpc/grpc/pull/31671
|
||||
Patch: %{forgeurl}/pull/31671.patch
|
||||
# [Test] Use ssl.SSLContext.wrap_socket, not ssl.wrap_socket
|
||||
#
|
||||
# The latter emits a DeprecationWarning since Python 3.10 and is removed
|
||||
# in Python 3.12.
|
||||
#
|
||||
# https://github.com/grpc/grpc/pull/33492
|
||||
#
|
||||
# Backported to 1.48.4.
|
||||
Patch: grpc-1.48.4-wrap_socket.patch
|
||||
# [Test] Do not use importlib find_module API, removed in Python 3.12
|
||||
# https://github.com/grpc/grpc/pull/33506
|
||||
#
|
||||
# Backported to 1.48.4.
|
||||
Patch: grpc-1.48.4-find_module.patch
|
||||
# Backport several #include directives
|
||||
# These were included in https://github.com/grpc/grpc/pull/30952
|
||||
#
|
||||
# [Fix] Added missing #include (#34359)
|
||||
# See: https://github.com/grpc/grpc/pull/34359
|
||||
#
|
||||
# Add abseil includes in test/cpp/end2end/xds/xds_server.h
|
||||
# Downstream-only because the current release, 1.60.0, builds without changes.
|
||||
#
|
||||
# Together, these fix compatibility with abseil-cpp-20240116.rc1.
|
||||
Patch: grpc-1.48.4-abseil-cpp-includes.patch
|
||||
|
||||
# [http2] Dont drop connections on metadata limit exceeded (#32309)
|
||||
#
|
||||
# * [http] Dont drop connections on metadata limit exceeded
|
||||
#
|
||||
# * remove bad test
|
||||
#
|
||||
# * Automated change: Fix sanity tests
|
||||
# https://github.com/grpc/grpc/commit/29d8beee0ac2555773b2a2dda5601c74a95d6c10
|
||||
# https://github.com/grpc/grpc/pull/32309
|
||||
#
|
||||
# Fixes CVE-2023-32732
|
||||
# https://nvd.nist.gov/vuln/detail/CVE-2023-32732
|
||||
# CVE-2023-32732 grpc: denial of service [fedora-all]
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=2214470
|
||||
#
|
||||
# Backported to 1.48.4.
|
||||
Patch: 0001-http2-Dont-drop-connections-on-metadata-limit-exceed.patch
|
||||
# [Python] Specify noexcept for cdef functions (#34242)
|
||||
#
|
||||
# This is needed to build grpc with Cython 3.
|
||||
#
|
||||
# https://github.com/grpc/grpc/issues/33918#issuecomment-1703386656
|
||||
# https://github.com/grpc/grpc/issues/33918#issuecomment-1788823585
|
||||
# https://github.com/grpc/grpc/pull/34242
|
||||
Patch: 0001-Specify-noexcept-for-cdef-functions.patch
|
||||
# [Python] Do not call PyEval_InitThreads
|
||||
# https://github.com/grpc/grpc/pull/34857
|
||||
Patch: %{forgeurl}/pull/34857.patch
|
||||
|
||||
Requires: grpc-data = %{version}-%{release}
|
||||
|
||||
@ -919,7 +976,7 @@ export GRPC_PYTHON_CFLAGS="$(
|
||||
export GRPC_PYTHON_LDFLAGS="$(pkg-config --libs protobuf)"
|
||||
%py3_build
|
||||
%{__python3} %{py_setup} %{?py_setup_args} install \
|
||||
-O1 --skip-build --root "${PYROOT}"
|
||||
-O1 --skip-build --root "${PYROOT}" --prefix %{_prefix}
|
||||
|
||||
# ~~ grpcio-tools ~~
|
||||
echo '===== Building Python grpcio_tools package =====' 2>&1
|
||||
@ -943,7 +1000,7 @@ export GRPC_PYTHON_LDFLAGS="$(pkg-config --libs protobuf) -lprotoc"
|
||||
# installed without an executable bit:
|
||||
find . -type f -name protoc.py -execdir sed -r -i '1{/^#!/d}' '{}' '+'
|
||||
%{__python3} %{py_setup} %{?py_setup_args} install \
|
||||
-O1 --skip-build --root "${PYROOT}"
|
||||
-O1 --skip-build --root "${PYROOT}" --prefix %{_prefix}
|
||||
popd >/dev/null
|
||||
|
||||
echo '===== Building pure-Python packages =====' 1>&2
|
||||
@ -961,7 +1018,7 @@ do
|
||||
fi
|
||||
%py3_build
|
||||
%{__python3} %{py_setup} %{?py_setup_args} install \
|
||||
-O1 --skip-build --root "${PYROOT}"
|
||||
-O1 --skip-build --root "${PYROOT}" --prefix %{_prefix}
|
||||
popd >/dev/null
|
||||
done
|
||||
|
||||
@ -1033,7 +1090,7 @@ done
|
||||
# - Reduces duplication and save space
|
||||
# - Respects system-wide administrative trust configuration
|
||||
# - Keeps “MPLv2.0” from having to be added to a number of License fields
|
||||
%global sysbundle %{_sysconfdir}/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
|
||||
%global sysbundle /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
|
||||
# We do not own this file; we temporarily install it in the buildroot so we do
|
||||
# not have dangling symlinks.
|
||||
install -D -t "%{buildroot}$(dirname '%{sysbundle}')" -m 0644 '%{sysbundle}'
|
||||
@ -1298,7 +1355,7 @@ alts_zero_copy_grpc_protector
|
||||
# Confirmed in 1.48.1 2022-09-13
|
||||
client_ssl
|
||||
|
||||
%ifarch s390x
|
||||
%ifarch s390x riscv64
|
||||
# Unexplained:
|
||||
#
|
||||
# [ RUN ] CredentialsTest.TestOauth2TokenFetcherCredsParsingEmptyHttpBody
|
||||
@ -1363,7 +1420,7 @@ examine_stack
|
||||
goaway_server
|
||||
%endif
|
||||
|
||||
%ifarch aarch64 x86_64 ppc64le s390x
|
||||
%ifarch aarch64 x86_64 ppc64le s390x riscv64
|
||||
# Unexplained:
|
||||
#
|
||||
# [ RUN ] GrpcToolTest.CallCommandWithTimeoutDeadlineSet
|
||||
@ -1434,7 +1491,7 @@ stack_tracer
|
||||
test_core_security_credentials
|
||||
%endif
|
||||
|
||||
%ifarch aarch64 x86_64 ppc64le s390x
|
||||
%ifarch aarch64 x86_64 ppc64le s390x riscv64
|
||||
# It looks like server_key_log has the right lines, but in an unexpected order.
|
||||
# It is not immediately obvious if this a real problem, or an implementation
|
||||
# quirk. Opinions about whether, or how, to report this upstream are welcome!
|
||||
@ -1535,16 +1592,11 @@ for suite in \
|
||||
test_py3_only
|
||||
do
|
||||
echo "==== $(date -u --iso-8601=ns): Python ${suite} ===="
|
||||
# See the implementation of the %%pytest macro, upon which our environment
|
||||
# setup is based. We add a timeout that is rather long, as it must apply to
|
||||
# the entire test suite. (Patching in a per-test timeout would be harder.)
|
||||
env CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" \
|
||||
LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}" \
|
||||
PATH="%{buildroot}%{_bindir}:$PATH" \
|
||||
PYTHONPATH="${PYTHONPATH:-%{buildroot}%{python3_sitearch}:%{buildroot}%{python3_sitelib}}" \
|
||||
PYTHONDONTWRITEBYTECODE=1 \
|
||||
timeout -k 31m -v 30m \
|
||||
%{__python3} %{py_setup} %{?py_setup_args} "${suite}"
|
||||
# See the implementation of the %%pytest macro, upon which the following is
|
||||
# based. We add a timeout that is rather long, as it must apply to the entire
|
||||
# test suite. (Patching in a per-test timeout would be harder.)
|
||||
%{py3_test_envvars} timeout -k 31m -v 30m \
|
||||
%{python3} %{py_setup} %{?py_setup_args} "${suite}"
|
||||
done
|
||||
popd
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user