Skip to content

Commit

Permalink
Removed redundant check
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-pbulawa committed Mar 5, 2024
1 parent 19980e5 commit 3690005
Showing 1 changed file with 8 additions and 16 deletions.
24 changes: 8 additions & 16 deletions src/main/java/net/snowflake/client/core/SFBaseSession.java
Original file line number Diff line number Diff line change
Expand Up @@ -392,38 +392,30 @@ public HttpClientSettingsKey getHttpClientKey() throws SnowflakeSQLException {
boolean httpUseProxy = Boolean.parseBoolean(systemGetProperty("http.useProxy"));
String httpProxyHost = systemGetProperty("http.proxyHost");
String httpProxyPort = systemGetProperty("http.proxyPort");
String httpProxyUser =
(systemGetProperty("http.proxyUser") != null) ? systemGetProperty("http.proxyUser") : "";
String httpProxyPassword =
(systemGetProperty("http.proxyPassword") != null)
? systemGetProperty("http.proxyPassword")
: "";
String httpProxyUser = systemGetProperty("http.proxyUser");
String httpProxyPassword = systemGetProperty("http.proxyPassword");
String httpsProxyHost = systemGetProperty("https.proxyHost");
String httpsProxyPort = systemGetProperty("https.proxyPort");
String httpsProxyUser =
(systemGetProperty("https.proxyUser") != null)
? systemGetProperty("https.proxyUser")
: "";
String httpsProxyPassword =
(systemGetProperty("https.proxyPassword") != null)
? systemGetProperty("https.proxyPassword")
: "";
String httpsProxyUser = systemGetProperty("https.proxyUser");
String httpsProxyPassword = systemGetProperty("https.proxyPassword");
String httpProxyProtocol = systemGetProperty("http.proxyProtocol");
String noProxy = systemGetEnv("NO_PROXY");
String nonProxyHosts = systemGetProperty("http.nonProxyHosts");
// log the JVM parameters that are being used
if (httpUseProxy) {
logger.debug(
"Proxy environment settings: http.useProxy={}, http.proxyHost={}, http.proxyPort={}, http.proxyUser={}, "
+ "https.proxyHost={}, https.proxyPort={}, https.proxyUser={}, http.nonProxyHosts={}, "
+ "NO_PROXY={}, http.proxyProtocol={}",
+ "http.proxyUser is {}, https.proxyHost={}, https.proxyPort={}, https.proxyUser={}, "
+ "https.proxyPassword is {}, http.nonProxyHosts={}, NO_PROXY={}, http.proxyProtocol={}",
httpUseProxy,
httpProxyHost,
httpProxyPort,
httpProxyUser,
httpProxyPassword == null || httpProxyPassword.isEmpty() ? "not set" : "set",
httpsProxyHost,
httpsProxyPort,
httpsProxyUser,
httpsProxyPassword == null || httpsProxyPassword.isEmpty() ? "not set" : "set",
nonProxyHosts,
noProxy,
httpProxyProtocol,
Expand Down

0 comments on commit 3690005

Please sign in to comment.