Skip to content

Commit

Permalink
[Rls] de-experimentalize RLS in XDS (grpc#33290)
Browse files Browse the repository at this point in the history
Integration tests are passing, so we should be ready to
de-experimentalize.

Related: internal bug b/265209578
  • Loading branch information
apolcyn authored and mario-vimal committed Jun 15, 2023
1 parent cc60212 commit 43098dc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/ext/xds/xds_route_config.cc
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,10 @@

namespace grpc_core {

// TODO(donnadionne): Remove once RLS is no longer experimental
// TODO(apolcyn): remove this flag by the 1.58 release
bool XdsRlsEnabled() {
auto value = GetEnv("GRPC_EXPERIMENTAL_XDS_RLS_LB");
if (!value.has_value()) return false;
if (!value.has_value()) return true;
bool parsed_value;
bool parse_succeeded = gpr_parse_bool_value(value->c_str(), &parsed_value);
return parse_succeeded && parsed_value;
Expand Down
1 change: 1 addition & 0 deletions test/core/xds/xds_route_config_resource_type_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1886,6 +1886,7 @@ TEST_F(RlsTest, NotUsedInAllVirtualHosts) {
}

TEST_F(RlsTest, ClusterSpecifierPluginsIgnoredWhenNotEnabled) {
testing::ScopedEnvVar env_var("GRPC_EXPERIMENTAL_XDS_RLS_LB", "false");
RouteConfiguration route_config;
route_config.set_name("foo");
auto* cluster_specifier_plugin = route_config.add_cluster_specifier_plugins();
Expand Down
2 changes: 2 additions & 0 deletions test/cpp/end2end/xds/xds_rls_end2end_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,8 @@ TEST_P(RlsTest, XdsRoutingClusterSpecifierPlugin) {
}

TEST_P(RlsTest, XdsRoutingClusterSpecifierPluginDisabled) {
grpc_core::testing::ScopedEnvVar env_var("GRPC_EXPERIMENTAL_XDS_RLS_LB",
"false");
CreateAndStartBackends(1);
// Populate new EDS resources.
EdsResourceArgs args({{"locality0", CreateEndpointsForBackends()}});
Expand Down

0 comments on commit 43098dc

Please sign in to comment.