From f2d3a68ff2f6ca7fcab48ef149c264d6a9f85a71 Mon Sep 17 00:00:00 2001 From: Kuat Date: Mon, 7 Dec 2020 15:21:01 -0800 Subject: [PATCH] update envoy to master (#3122) * update envoy to master Signed-off-by: Kuat Yessenov * stale file Signed-off-by: Kuat Yessenov --- WORKSPACE | 6 +++--- extensions/BUILD | 9 ++++----- extensions/metadata_exchange/BUILD | 4 ---- src/envoy/http/alpn/alpn_filter.cc | 3 ++- src/envoy/http/alpn/alpn_test.cc | 9 ++++++--- .../istio_http_integration_test_with_envoy_jwt_filter.cc | 5 +++-- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/WORKSPACE b/WORKSPACE index 485c03f1c59..c93c7c1a450 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -38,10 +38,10 @@ bind( # 2. Update .bazelversion, envoy.bazelrc and .bazelrc if needed. # # Note: this is needed by release builder to resolve envoy dep sha to tag. -# Commit date: 2020-11-20 -ENVOY_SHA = "31e225b628a316322a0bcbd237a143eade995d22" +# Commit date: 2020-12-07 +ENVOY_SHA = "ebdcf7cc28dfeb555a957096231fdec343de4709" -ENVOY_SHA256 = "079516e413c07e2ca19374c9baa1cafe7c6ee1b160e74c6427b9fee0709fa953" +ENVOY_SHA256 = "939b31eeb2a97df0611dc576d5c6e0cc7e63518fe925a0a48b42e05fd2df614e" ENVOY_ORG = "envoyproxy" diff --git a/extensions/BUILD b/extensions/BUILD index 42710a32530..842fe01a426 100644 --- a/extensions/BUILD +++ b/extensions/BUILD @@ -17,7 +17,7 @@ load( "@envoy//bazel/wasm:wasm.bzl", - "wasm_cc_binary", + "envoy_wasm_cc_binary", ) load( "@envoy//bazel:envoy_build_system.bzl", @@ -26,7 +26,7 @@ load( envoy_package() -wasm_cc_binary( +envoy_wasm_cc_binary( name = "stats.wasm", srcs = [ "//extensions/common:context.cc", @@ -42,12 +42,11 @@ wasm_cc_binary( "//extensions/common/wasm:json_util", "//external:abseil_strings", "//external:abseil_time", - "@proxy_wasm_cpp_sdk//:proxy_wasm_intrinsics", "@proxy_wasm_cpp_sdk//contrib:contrib_lib", ], ) -wasm_cc_binary( +envoy_wasm_cc_binary( name = "metadata_exchange.wasm", srcs = [ "//extensions/common:context.cc", @@ -72,7 +71,7 @@ wasm_cc_binary( ], ) -wasm_cc_binary( +envoy_wasm_cc_binary( name = "attributegen.wasm", srcs = [ "//extensions/attributegen:plugin.cc", diff --git a/extensions/metadata_exchange/BUILD b/extensions/metadata_exchange/BUILD index 7fe7d986203..37e910443fb 100644 --- a/extensions/metadata_exchange/BUILD +++ b/extensions/metadata_exchange/BUILD @@ -5,10 +5,6 @@ load( "envoy_cc_library", "envoy_package", ) -load( - "@envoy//bazel/wasm:wasm.bzl", - "wasm_cc_binary", -) envoy_package() diff --git a/src/envoy/http/alpn/alpn_filter.cc b/src/envoy/http/alpn/alpn_filter.cc index 089a738c1a2..535cd00328d 100644 --- a/src/envoy/http/alpn/alpn_filter.cc +++ b/src/envoy/http/alpn/alpn_filter.cc @@ -67,7 +67,8 @@ Http::FilterHeadersStatus AlpnFilter::decodeHeaders(Http::RequestHeaderMap &, } Upstream::ThreadLocalCluster *cluster = - config_->clusterManager().get(route_entry->clusterName()); + config_->clusterManager().getThreadLocalCluster( + route_entry->clusterName()); if (!cluster || !cluster->info()) { ENVOY_LOG(debug, "cannot find cluster {}", route_entry->clusterName()); return Http::FilterHeadersStatus::Continue; diff --git a/src/envoy/http/alpn/alpn_test.cc b/src/envoy/http/alpn/alpn_test.cc index 646c1f513e7..1970196d1f7 100644 --- a/src/envoy/http/alpn/alpn_test.cc +++ b/src/envoy/http/alpn/alpn_test.cc @@ -85,7 +85,8 @@ TEST_F(AlpnFilterTest, OverrideAlpnUseDownstreamProtocol) { {Http::Protocol::Http2, {"qux"}}}; auto filter = makeAlpnOverrideFilter(alpn); - ON_CALL(cluster_manager_, get(_)).WillByDefault(Return(fake_cluster_.get())); + ON_CALL(cluster_manager_, getThreadLocalCluster(_)) + .WillByDefault(Return(fake_cluster_.get())); ON_CALL(*fake_cluster_, info()).WillByDefault(Return(cluster_info_)); ON_CALL(*cluster_info_, upstreamHttpProtocol(_)) .WillByDefault([](absl::optional protocol) { @@ -121,7 +122,8 @@ TEST_F(AlpnFilterTest, OverrideAlpn) { {Http::Protocol::Http2, {"qux"}}}; auto filter = makeAlpnOverrideFilter(alpn); - ON_CALL(cluster_manager_, get(_)).WillByDefault(Return(fake_cluster_.get())); + ON_CALL(cluster_manager_, getThreadLocalCluster(_)) + .WillByDefault(Return(fake_cluster_.get())); ON_CALL(*fake_cluster_, info()).WillByDefault(Return(cluster_info_)); ON_CALL(*cluster_info_, upstreamHttpProtocol(_)) .WillByDefault( @@ -155,7 +157,8 @@ TEST_F(AlpnFilterTest, EmptyOverrideAlpn) { {Http::Protocol::Http11, {"baz"}}}; auto filter = makeAlpnOverrideFilter(alpn); - ON_CALL(cluster_manager_, get(_)).WillByDefault(Return(fake_cluster_.get())); + ON_CALL(cluster_manager_, getThreadLocalCluster(_)) + .WillByDefault(Return(fake_cluster_.get())); ON_CALL(*fake_cluster_, info()).WillByDefault(Return(cluster_info_)); ON_CALL(*cluster_info_, upstreamHttpProtocol(_)) .WillByDefault( diff --git a/test/integration/istio_http_integration_test_with_envoy_jwt_filter.cc b/test/integration/istio_http_integration_test_with_envoy_jwt_filter.cc index 154fe291652..4f1cd430753 100644 --- a/test/integration/istio_http_integration_test_with_envoy_jwt_filter.cc +++ b/test/integration/istio_http_integration_test_with_envoy_jwt_filter.cc @@ -213,8 +213,9 @@ class IstioHttpIntegrationTestWithEnvoyJwtFilter public: void createUpstreams() override { HttpProtocolIntegrationTest::createUpstreams(); - fake_upstreams_.emplace_back(new FakeUpstream( - 0, FakeHttpConnection::Type::HTTP2, version_, timeSystem())); + FakeUpstreamConfig config(timeSystem()); + config.upstream_protocol_ = FakeHttpConnection::Type::HTTP2; + fake_upstreams_.emplace_back(new FakeUpstream(0, version_, config)); zipkin_upstream_ = fake_upstreams_.back().get(); }