Do not register max-age filter when chaotic-good is enabled.

pull/36311/head
Junhua Yan 10 months ago
parent 1e5fc3df8b
commit d7cee5f094
  1. 16
      src/core/ext/filters/channel_idle/legacy_channel_idle_filter.cc

@ -307,13 +307,15 @@ void RegisterLegacyChannelIdleFilters(CoreConfiguration::Builder* builder) {
.If([](const ChannelArgs& channel_args) {
return GetClientIdleTimeout(channel_args) != Duration::Infinity();
});
builder->channel_init()
->RegisterV2Filter<LegacyMaxAgeFilter>(GRPC_SERVER_CHANNEL)
.ExcludeFromMinimalStack()
.If([](const ChannelArgs& channel_args) {
return LegacyMaxAgeFilter::Config::FromChannelArgs(channel_args)
.enable();
});
if (!grpc_core::IsChaoticGoodEnabled()) {
builder->channel_init()
->RegisterV2Filter<LegacyMaxAgeFilter>(GRPC_SERVER_CHANNEL)
.ExcludeFromMinimalStack()
.If([](const ChannelArgs& channel_args) {
return LegacyMaxAgeFilter::Config::FromChannelArgs(channel_args)
.enable();
});
}
}
LegacyMaxAgeFilter::LegacyMaxAgeFilter(grpc_channel_stack* channel_stack,

Loading…
Cancel
Save