Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions bazel/external/quiche.BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ envoy_cc_library(
"quiche/http2/adapter/http2_session.h",
"quiche/http2/adapter/http2_util.h",
"quiche/http2/adapter/http2_visitor_interface.h",
"quiche/http2/adapter/nghttp2.h",
"quiche/http2/adapter/nghttp2_adapter.h",
"quiche/http2/adapter/nghttp2_callbacks.h",
"quiche/http2/adapter/nghttp2_data_provider.h",
Expand All @@ -146,6 +147,8 @@ envoy_cc_library(
":spdy_core_header_block_lib",
":spdy_core_http2_deframer_lib",
":spdy_core_protocol_lib",
":spdy_header_byte_listener_interface_lib",
":spdy_no_op_headers_handler_lib",
],
)

Expand Down Expand Up @@ -864,6 +867,26 @@ envoy_cc_library(
],
)

envoy_cc_library(
name = "spdy_no_op_headers_handler_lib",
hdrs = ["quiche/spdy/core/no_op_headers_handler.h"],
repository = "@envoy",
visibility = ["//visibility:public"],
deps = [
":quiche_common_platform",
],
)

envoy_cc_library(
name = "spdy_header_byte_listener_interface_lib",
hdrs = ["quiche/spdy/core/header_byte_listener_interface.h"],
repository = "@envoy",
visibility = ["//visibility:public"],
deps = [
":quiche_common_platform",
],
)

envoy_cc_library(
name = "spdy_core_alt_svc_wire_format_lib",
srcs = ["quiche/spdy/core/spdy_alt_svc_wire_format.cc"],
Expand Down
99 changes: 0 additions & 99 deletions bazel/external/quiche.patch
Original file line number Diff line number Diff line change
@@ -1,99 +0,0 @@
--- http2/adapter/callback_visitor.h

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

YAY! Let's see if this sticks!!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to remove quiche.patch from any build files?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought about it and my conclusion was that we're inevitably going to need this file again one day so I'd rather keep it as an empty file for now (as opposed to deleting the file and all references to it) to make it easier to bring it back if needed later

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I see. I really hope that we never need it again since we don't need it for Chrome. But that's probably Pollyanna-ish. SGTM!

+++ http2/adapter/callback_visitor.h
@@ -8,6 +8,10 @@
#include "absl/container/flat_hash_map.h"
#include "http2/adapter/http2_visitor_interface.h"
#include "http2/adapter/nghttp2_util.h"
+
+// Required to build on Windows.
+typedef ptrdiff_t ssize_t;
+
#include "third_party/nghttp2/src/lib/includes/nghttp2/nghttp2.h"
#include "common/platform/api/quiche_export.h"

--- http2/adapter/http2_protocol.h
+++ http2/adapter/http2_protocol.h
@@ -10,6 +10,8 @@
#include "absl/types/variant.h"
#include "common/platform/api/quiche_export.h"

+#undef NO_ERROR
+
namespace http2 {
namespace adapter {

--- http2/adapter/nghttp2_callbacks.h
+++ http2/adapter/nghttp2_callbacks.h
@@ -5,6 +5,10 @@

#include "http2/adapter/http2_protocol.h"
#include "http2/adapter/nghttp2_util.h"
+
+// Required to build on Windows.
+typedef ptrdiff_t ssize_t;
+
#include "third_party/nghttp2/src/lib/includes/nghttp2/nghttp2.h"

namespace http2 {
--- http2/adapter/nghttp2_data_provider.h
+++ http2/adapter/nghttp2_data_provider.h
@@ -5,6 +5,10 @@
#include <memory>

#include "http2/adapter/data_source.h"
+
+// Required to build on Windows.
+typedef ptrdiff_t ssize_t;
+
#include "third_party/nghttp2/src/lib/includes/nghttp2/nghttp2.h"

namespace http2 {
--- http2/adapter/nghttp2_session.h
+++ http2/adapter/nghttp2_session.h
@@ -5,6 +5,10 @@

#include "http2/adapter/http2_session.h"
#include "http2/adapter/nghttp2_util.h"
+
+// Required to build on Windows.
+typedef ptrdiff_t ssize_t;
+
#include "third_party/nghttp2/src/lib/includes/nghttp2/nghttp2.h"
#include "common/platform/api/quiche_export.h"

--- http2/adapter/nghttp2_util.h
+++ http2/adapter/nghttp2_util.h
@@ -10,6 +10,10 @@
#include "absl/types/span.h"
#include "http2/adapter/data_source.h"
#include "http2/adapter/http2_protocol.h"
#include "http2/adapter/http2_visitor_interface.h"
+
+// Required to build on Windows.
+typedef ptrdiff_t ssize_t;
+
#include "third_party/nghttp2/src/lib/includes/nghttp2/nghttp2.h"
#include "spdy/core/spdy_header_block.h"

--- http2/adapter/http2_util.cc
+++ http2/adapter/http2_util.cc
@@ -1,5 +1,7 @@
#include "third_party/http2/adapter/http2_util.h"

+#undef NO_ERROR
+
namespace http2 {
namespace adapter {
namespace {

--- http2/adapter/oghttp2_session.cc
+++ http2/adapter/oghttp2_session.cc
@@ -11,6 +11,8 @@
#include "http2/adapter/oghttp2_util.h"
#include "spdy/core/spdy_protocol.h"

+#undef NO_ERROR
+
namespace http2 {
namespace adapter {

6 changes: 3 additions & 3 deletions bazel/repository_locations.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -838,12 +838,12 @@ REPOSITORY_LOCATIONS_SPEC = dict(
project_name = "QUICHE",
project_desc = "QUICHE (QUIC, HTTP/2, Etc) is Google‘s implementation of QUIC and related protocols",
project_url = "https://github.com/google/quiche",
version = "4f552f349b8df000af24bc6cfa0b78fdc2467fef",
sha256 = "355c80803698d2a44363ed304d250059cc5d7712281481803717f8d779229bd8",
version = "81314ecbd8cfd3c8399fcd1c1e7ca557b41d18de",
sha256 = "61e28bf91daba19f65af53b19fbefd5876b3365835e7c0091ccf0c91dba72ba6",
urls = ["https://github.com/google/quiche/archive/{version}.tar.gz"],
strip_prefix = "quiche-{version}",
use_category = ["dataplane_core"],
release_date = "2021-11-15",
release_date = "2021-11-17",
cpe = "N/A",
),
com_googlesource_googleurl = dict(
Expand Down
2 changes: 1 addition & 1 deletion source/common/http/http2/codec_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -902,7 +902,7 @@ int ConnectionImpl::onData(int32_t stream_id, const uint8_t* data, size_t len) {
void ConnectionImpl::goAway() {
if (use_new_codec_wrapper_) {
adapter_->SubmitGoAway(adapter_->GetHighestReceivedStreamId(),
http2::adapter::Http2ErrorCode::NO_ERROR, "");
http2::adapter::Http2ErrorCode::HTTP2_NO_ERROR, "");
} else {
int rc = nghttp2_submit_goaway(session_, NGHTTP2_FLAG_NONE,
nghttp2_session_get_last_proc_stream_id(session_),
Expand Down