Skip to content

Commit

Permalink
Merge pull request #47 from keizer619/jdk11
Browse files Browse the repository at this point in the history
Update stage and dev central urls
  • Loading branch information
keizer619 authored Oct 22, 2020
2 parents 2f6ce77 + 055a70b commit 8bb3a61
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/main/java/org/ballerinalang/command/util/ToolUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,15 +56,15 @@
*/
public class ToolUtil {
private static final String PRODUCTION_URL = "https://api.central.ballerina.io/1.0/update-tool";
private static final String STAGING_URL = "https://api.staging-central.ballerina.io/update-tool";
private static final String PREPROD_URL = "https://api.preprod-central.ballerina.io/1.0/update-tool";
private static final String STAGING_URL = "https://api.staging-central.ballerina.io/1.0/update-tool/";
private static final String DEV_URL = "https://api.dev-central.ballerina.io/1.0/update-tool/";
public static final String CLI_HELP_FILE_PREFIX = "dist-";
private static final String BALLERINA_1_X_VERSIONS = "1.0.";
private static final String CONNECTION_ERROR_MESSAGE = "connection to the remote server failed";
public static final boolean BALLERINA_DEV_STAGE_UPDATE = Boolean.parseBoolean(
System.getenv("BALLERINA_DEV_STAGE_UPDATE"));
public static final boolean BALLERINA_DEV_PREPROD_UPDATE = Boolean.parseBoolean(
System.getenv("BALLERINA_DEV_PREPROD_UPDATE"));
public static final boolean BALLERINA_STAGING_UPDATE = Boolean.parseBoolean(
System.getenv("BALLERINA_STAGING_UPDATE"));
public static final boolean BALLERINA_DEV_UPDATE = Boolean.parseBoolean(
System.getenv("BALLERINA_DEV_UPDATE"));

private static TrustManager[] trustAllCerts = new TrustManager[]{
new X509TrustManager() {
Expand Down Expand Up @@ -772,8 +772,8 @@ private static String getServerRequestFailedErrorMessage(HttpURLConnection conn)
*/
private static String getServerURL() {
String url = PRODUCTION_URL;
url = BALLERINA_DEV_STAGE_UPDATE ? STAGING_URL : url;
url = BALLERINA_DEV_PREPROD_UPDATE ? PREPROD_URL : url;
url = BALLERINA_STAGING_UPDATE ? STAGING_URL : url;
url = BALLERINA_DEV_UPDATE ? DEV_URL : url;
return url;
}

Expand Down

0 comments on commit 8bb3a61

Please sign in to comment.