Skip to content

Commit 643ef5f

Browse files
committed
Adjust cilium custom filters
Signed-off-by: Tam Mach <[email protected]>
1 parent d069163 commit 643ef5f

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

cilium/grpc_subscription.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -183,13 +183,13 @@ subscribe(const std::string& type_url, const LocalInfo::LocalInfo& local_info,
183183
Config::SubscriptionFactory::RetryInitialDelayMs,
184184
Config::SubscriptionFactory::RetryMaxDelayMs, random),
185185
/*target_xds_authority_=*/"",
186-
/*eds_resources_cache_=*/nullptr // EDS cache is only used for ADS.
186+
/*eds_resources_cache_=*/nullptr, // EDS cache is only used for ADS.
187+
/*skip_subsequent_node_=*/api_config_source.set_node_on_first_message_only(),
187188
};
188189

189190
return std::make_unique<Config::GrpcSubscriptionImpl>(
190-
std::make_shared<GrpcMuxImpl>(grpc_mux_context,
191-
api_config_source.set_node_on_first_message_only()),
192-
callbacks, resource_decoder, stats, type_url, dispatcher, init_fetch_timeout,
191+
std::make_shared<GrpcMuxImpl>(grpc_mux_context), callbacks, resource_decoder, stats, type_url,
192+
dispatcher, init_fetch_timeout,
193193
/*is_aggregated*/ false, options);
194194
}
195195

cilium/grpc_subscription.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ extern envoy::config::core::v3::ConfigSource cilium_xds_api_config;
2525
// GrpcMux wrapper to get access to control plane identifier
2626
class GrpcMuxImpl : public Config::GrpcMuxImpl {
2727
public:
28-
GrpcMuxImpl(Config::GrpcMuxContext& grpc_mux_context, bool skip_subsequent_node)
29-
: Config::GrpcMuxImpl(grpc_mux_context, skip_subsequent_node) {}
28+
explicit GrpcMuxImpl(Config::GrpcMuxContext& grpc_mux_context)
29+
: Config::GrpcMuxImpl(grpc_mux_context) {}
3030

3131
~GrpcMuxImpl() override = default;
3232

cilium/secret_watcher.cc

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -156,15 +156,14 @@ DownstreamTLSContext::DownstreamTLSContext(const NetworkPolicyMapImpl& parent,
156156
server_names_.emplace_back(config.server_names(i));
157157
}
158158
auto server_config_or_error = Extensions::TransportSockets::Tls::ServerContextConfigImpl::create(
159-
context_config, parent.transportFactoryContext(), false);
159+
context_config, parent.transportFactoryContext(), server_names_, false);
160160
// NOLINTNEXTLINE(performance-unnecessary-copy-initialization)
161161
THROW_IF_NOT_OK(server_config_or_error.status());
162162
server_config_ = std::move(server_config_or_error.value());
163163

164164
auto create_server_context = [this]() {
165165
ENVOY_LOG(debug, "Server secret is updated.");
166-
auto ctx_or_error =
167-
manager_.createSslServerContext(scope_, *server_config_, server_names_, nullptr);
166+
auto ctx_or_error = manager_.createSslServerContext(scope_, *server_config_, nullptr);
168167
// NOLINTNEXTLINE(performance-unnecessary-copy-initialization)
169168
THROW_IF_NOT_OK(ctx_or_error.status());
170169
auto ctx = std::move(ctx_or_error.value());

0 commit comments

Comments
 (0)