Skip to content

Commit

Permalink
xds: change system property for reading bootstrap config (#7961)
Browse files Browse the repository at this point in the history
Changes from "io.grpc.xds.bootstrapValue" to "io.grpc.xds.bootstrapConfig".
  • Loading branch information
voidzcy committed Mar 12, 2021
1 parent 9c562c8 commit 8e1c9b6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions xds/src/main/java/io/grpc/xds/BootstrapperImpl.java
Expand Up @@ -54,9 +54,9 @@ public class BootstrapperImpl extends Bootstrapper {
private static final String BOOTSTRAP_CONFIG_SYS_ENV_VAR = "GRPC_XDS_BOOTSTRAP_CONFIG";
@VisibleForTesting
static String bootstrapConfigFromEnvVar = System.getenv(BOOTSTRAP_CONFIG_SYS_ENV_VAR);
private static final String BOOTSTRAP_CONFIG_SYS_PROPERTY_VAR = "io.grpc.xds.bootstrapValue";
private static final String BOOTSTRAP_CONFIG_SYS_PROPERTY = "io.grpc.xds.bootstrapConfig";
@VisibleForTesting
static String bootstrapConfigFromSysProp = System.getProperty(BOOTSTRAP_CONFIG_SYS_PROPERTY_VAR);
static String bootstrapConfigFromSysProp = System.getProperty(BOOTSTRAP_CONFIG_SYS_PROPERTY);
private static final String XDS_V3_SERVER_FEATURE = "xds_v3";
@VisibleForTesting
static final String CLIENT_FEATURE_DISABLE_OVERPROVISIONING =
Expand Down Expand Up @@ -105,7 +105,7 @@ public BootstrapInfo bootstrap() throws XdsInitializationException {
+ "- " + BOOTSTRAP_CONFIG_SYS_ENV_VAR + "\n\n"
+ "Java System Properties searched:\n"
+ "- " + BOOTSTRAP_PATH_SYS_PROPERTY + "\n"
+ "- " + BOOTSTRAP_CONFIG_SYS_PROPERTY_VAR + "\n\n");
+ "- " + BOOTSTRAP_CONFIG_SYS_PROPERTY + "\n\n");
}

logger.log(XdsLogLevel.INFO, "Reading bootstrap from " + filePath);
Expand Down
Expand Up @@ -60,7 +60,7 @@ final class GoogleCloudToProdNameResolver extends NameResolver {
System.getenv("GRPC_XDS_BOOTSTRAP") != null
|| System.getProperty("io.grpc.xds.bootstrap") != null
|| System.getenv("GRPC_XDS_BOOTSTRAP_CONFIG") != null
|| System.getProperty("io.grpc.xds.bootstrapValue") != null;
|| System.getProperty("io.grpc.xds.bootstrapConfig") != null;

private HttpConnectionProvider httpConnectionProvider = HttpConnectionFactory.INSTANCE;
private final String authority;
Expand Down

0 comments on commit 8e1c9b6

Please sign in to comment.